Interface for AJAX elements in various pages.
Load the class through FACTORY: $this->ajax = FACTORY_AJAX::getInstance();
version | 1.0 |
---|---|
author | Mark Grimshaw |
package | wikindx4\core\ajax |
__construct()
decode_jString(string $jsonString, boolean $stripslashes, boolean $array) : mixed
string
The JSON string
boolean
In WIKINDX, querystrings are slashed. Default is TRUE.
boolean
If TRUE (default), return associative array, otherwise return object.
mixed
Array or objectencode_jArray(array $jsonArray, boolean $quote) : string
array
The unformatted JSON array
boolean
No encoding of quotation marks (") if set to FALSE. Default is FALSE.
string
The JSON stringjActionForm(string $action, array $jsonArray, boolean $return)
string
The javascript action such as 'onclick' etc.
array
The parameter to be passed to gateway() as an array ready to be converted to JSON
boolean
If TRUE, generated javascript has a return from the gateway() function. Default is FALSE.
jActionIcon(string $icon, string $action, array $jsonArray, boolean $return) : string
Works with core/display/LOADICONS.php.
string
The icon to make an image of ('add', 'delete', 'view' etc.)
string
The javascript action such as 'onclick' etc.
array
The parameter to be passed to gateway() as an array ready to be converted to JSON
boolean
If TRUE, generated javascript has a return from the gateway() function. Default is FALSE.
string
The image tagloadJavascript(mixed $scripts)
mixed
Either an array of .js scripts to load or a single string. It can be FALSE.
jsonMap(string $value)
string
json_error(string $type)
string