Skip to main content
NICE CXone Expert
Expert Success Center

Definitions and Operators in DekiScript

Commonly used DekiScript definitions and operators can help you customize your Expert content.

DekiScript definitions

Comment

//<text> 

The key to writing good code is to leave comments along the way explaining why you chose to do things the way you did. Use two forward slashes // to comment out text that is not to be displayed. Comments are notes to yourself and to other coders explaining your code. Comments do not affect your code.

//This is a comment

Try it on a page: Open a page in Edit mode. Copy the above code and click Save. You will see:

[nothing, since comments can only be seen in the editor].

Text

"<text>"

Anything between quotation marks is a string of text.

"This is text"

Try it on a page: Open a page in Edit mode. Copy the above code and click Save. You will see:   

This is text

Hyperlink

<a href="http://www.hyperlink.com">"Text for your hyperlink"</a>

In DekiScript, hyperlinks are created the same way they are created in HTML. Just place the URL between quotation marks after the href, and the text that you want to link to between quotation marks before the </a> tag.

<a href="http://www.mindtouch.com">"MindTouch"</a>

Try it on a page:  Open a page in Edit mode. Copy the above code and click Save. You will see:

 MindTouch

Concatenate

"..x.."

Two periods before and after a variable connects the variable's value to the text before and after it.

var x=5;
var y=6;
""..x..""..y..""

Try it on a page: Open a page in Edit mode. Copy the above code and click Save. You will see:

56

Line break

<br/>

A line break pushes the text that follows to the next line.

"Today you are learning DekiScript.";<br/>
"Don't forget to put a semicolon after the text and before the line break.";

Try it on a page: Open a page in Edit mode. Copy the above code and click Save. You will see:

Today you are learning DekiScript.
Don't forget to put a semicolon after the text and before the line break.

Line space

<br/><br/>

A line space adds a blank line after your text. It does what pressing the enter key twice would do. 

"Today you are learning DekiScript.";<br/><br/>
"Don't forget to put a semicolon after the text and before the line break or line space.";

Try it on a page: Open a page in Edit mode. Copy the above code and click Save. You will see:

Today you are learning DekiScript.

Don't forget to put a semicolon after the text and before the line break or line space.

DekiScript operators

Operator Description
= sets something
== compares things
&& and
|| or
!= does not
() allows DekiScript in HTML

 

  • Was this article helpful?