Categories
Coding

XtScript: Variable

Working with variable in XtScript can be imagined like combining variable in Javascript and PHP. Variable in xtscript must be declared first using var keyword, followed by $ sign next to the variable name and = as the variable value. Characters that are legal to be used as a variable name in xtscript is letters […]

Categories
Coding

XtScript: Function

What is function? Function is a block of codes which have it’s own name and arguments passed in it and can be reused over and over again. Creating a function can save your time in coding, that’s also apply in XtScript of course. Function in XtScript are declared using function keyword followed by function name […]

Categories
Coding

XtScript: Include

Having a long XtScript codes in one block could be confusing and hard to manage especially on mobile device with small screen. That’s when the include command come in handy. We can load external XtScript file and use on our codes using include command. XtScript file has .xt extension. After we have included an XtScript […]

Categories
Coding

XtScript: Comments

Writing comments in your code works is a good habbit Comments in script can help other people understand better your work or also help yourself when you are back working the codes after a long break. Comments in XtScript are declared using: • # for a single line comment. • /* */ for multi lines […]

Categories
Coding

XtScript: Goto

goto (“Go to”) is a command in XtScript to jump to certain jump point declared in the script. The jump point used in Goto command is declared using @ prefix. goto is a command that most useful for creating loop function in XtScript. Learn XtScript Goto from examples Creating a simple loop by make use […]

Categories
Coding

XtScript: Conjunction – Logical Operators

Conjunction operator is used to to make the conditional operator in XtScript to be more effective. We can create a conditional statement containing different arguments by chaining them using conjunction operator. XtScript Conjunction Operators Operator Syntax example Summary or $a or $b The condition is true either $a or $b return true not not $a […]

Categories
Coding

XtScript: Conditional Operators

Conditional operators is a way to make a dynamic output of our XtScript codes based on the certain conditions included. If you are familiar with conditional operator in Javascript or PHP, you will not find hard time in learning conditional operators in XtScript. Conditional operation in XtScript begin with if and closed with endif. XtScript […]

Categories
Coding

XtScript: Get

get is a command in XtScript to get the value of information passed to the server via GET or POST method. It is similar to GET() function in PHP. Unlike in PHP, the information sent to the server are retrieved using only only one keyword (get) whether the method is GET either POST. Differences in […]

Categories
Coding

XtScript: Comparison – Logical Operators

Comparison operator is used to compare and evaluate of two different variable. Comparison operator is mainly useful in the XtScript conditional operation. XtScript Comparison Operators Operator Syntax example Summary == $a == $b Return true if the variable $a and $b are: “Equals to”, “Same with”, “Has same value with”. != $a != $b Return […]

Categories
Coding

XtScript: Delete

delete is a command in XtScript to unset or remove a variable declaration. Delete can be declared using two keywords: • del • delete However because del is simply shorter, we will use it along our examples. Learn XtScript Delete command from examples Use delete to unset a variable. <!–parser:xtscript–> var $content = Television, aquarium, […]