DATA Methods
Database functions
select(), fetch(), write(), update(), delete(), execute(), tables(), fields()Requests and temporary storage
request(), cookie(), session(), config(), store()Formatting data
encode(), decode(), json(), text(), date(), weekday(), month()Template data
content(), parents(), directory()
decode()
Decode data that has been encoded by the encode() function.
string decode( string text [, int type = 1 ])
Return
Decoded text.
Parameter
Description
textText to be decoded.
type0 = no encoding
1 = html-entities QUOTES
2 = html-entities NOQUOTES
3 = url-encode
4 = json-encode
5 = javascript encode
For more information on how to use javascript encoding, see encode() for details.
1 = html-entities QUOTES
2 = html-entities NOQUOTES
3 = url-encode
4 = json-encode
5 = javascript encode
For more information on how to use javascript encoding, see encode() for details.
Decode encoded text
$DATA->decode("<script>alert('test')</script>")
RETURN: '<script>alert('test')</script>'