Updated Articles

  1. sgapiRand(%%min, %%max)

    This is equivalent to the mt_rand function in PHP. It generates a random number (typically 9 or 10 digits long). If the optional %%min and %%max integers are specified, it will generate a number between %%min and %%max instead.  To see an...
  2. sgapiSqrt(%%number)

    This is equivalent to the sqrt function in PHP. It returns the square root of the value in %%number. To see an example or learn more other PHP functions and PHP programming, visit PHP Documentation . ...
  3. sgapiIs_Null(%%variable)

    This is equivalent to the is_null function in PHP. Returns either TRUE or FALSE if the variable passed is null. To see an example or learn more other PHP functions and PHP programming visit PHP Documentation . ...
  4. sgapiMd5(%%string)

    This is equivalent to the md5 function in PHP. It returns the MD5 hash of the provided string. Can be used to compare two strings for an exact match by comparing their MD5 hash values. To see an example or learn more other PHP functions a...
  5. sgapiStrCaseCmp(%%str1,%%str2,%%case=false)

    This is equivalent to the strcasecmp function in PHP. This function will compare %%str1 with %%str2 in a case-insensitive manner when %%case=false. The results are returned as either a negative number (str1 < str2), 0 (match), or a positive numbe...
  6. sgapiIn_Array(%%needle,%%haystack,%%strict)

    This is equivalent to the in_array function in PHP. It searches the array %%haystack for %%needle. Setting %%strict to TRUE will also check the type of the needle in the haystack. To see an example or learn more other PHP functions and PH...
  7. sgapiStrLen(%%string)

    This is the equivalent of the strlen function. This function returns the length of the string. Example The below example will return the string length entered in the textbox from question ID 2. Check it out in an Example Survey ...
  8. sgapiArray_Rand(%%array,%%number)

    This function is the equivalent of the array_rand function in PHP. Picks one or more random entries out of an array, and returns the key (or keys) of the random entries. %%arr = the defined array. %%number = the number of returned array ...
  9. sgapiArray_Pop(%%array)

    This is the equivalent of the array_pop function in PHP. Given an array this function will return the last element of the array and remove that element from the array itself. To see an example or learn more other PHP functions and PHP progr...
  10. sgapiArrayMerge(%%array1,%%array2)

    This is equivalent to the array_merge function in PHP. Given two arrays this function will append the elements of %%array2 to the end of %%array1 and return combined elements (the array is reindexed). To see an example or learn more other...