All Commands
All Variables
Commands
SET
Set a variable.
Standard Variables should start with V_. e.g. V_NAME or V_SIZE.
Starting with V_ is not mandatory but the code will run faster and it will save you creating a variable name that clashes with a System Command.
Special Variables can be set individually using the names SPVAR01 to SPVAR04 or SPVAR1 to SPVAR4.
You can set multiple Special Variables at once using the name SPVAR and supplying and list of values in the form [v1, v2, v3].
You can set session variables by strting the variable name with V_SES_. e.g. {SET(V_SES_PAGE, 1234)}.
These will persist between pages but will not work once the user has left the site. They are also not setup to hold arrays.
You can set Persistent user variables by prefixing the name with "USER_".
These will remain even after the user has logged out and back in again on another machine.
You should only use these for users who are logged in. They are also not capable of holding arrays.
This command can have an {END_SET} command.
In this case, the last parameter can be excluded from the arguments and the area between the {SET()} and {END_SET} will be used instead.
Number | Name | Default | Type | Description |
---|---|---|---|---|
1 | name | String | Variable Name. |
|
2 | value | String | Value |
Multiple Set Example
Standard Example
Array Example
[1:DEF]
[9:123]
[W:XYZ]
VARIABLE Commands
ADDARRAY_CLEAR
ARRAY_JOIN
ARRAY_JSON
ARRAY_QTY_IN
ARRAY_SIZE
DDQUOTE
EMPTY
GET
GET_XML
IS_SET
ORDINAL
SET_XML
VAR
VARS