SetEncoding()
Sets the character encoding (character set) of Form and URL scope variable values.
Used when the character encoding of the input to a form, or the character encoding of a URL, is not in UTF-8 encoding.
SetEncoding( scope=string, encoding=string );
Returns: String
| Argument | Description |
|---|---|
|
scope
string,
required
|
edit
url, form |
|
encoding
string,
required
|
edit
The character encoding in which text in the scope variables is encoded |
Examples
edit my_data = SetEncoding("url", "euc-jp");
my_scope = getEncoding("url");
dump(my_scope); // UTF-8
See also
- Search Issue Tracker open_in_new
- Search Lucee Test Cases open_in_new (good for further, detailed examples)