Core Function ResolveStr
From Sputnik Wiki
ResolveStr( <expression>, <allowEscapes>, <allowVariables>, <allowCode> )
Contents |
Description
Treat a given string as if it was a Sputnik "string" and parse all stuff inside it such as $variables etc.
Parameters
expression
The string to use.
allowEscapes
True to allow parsing of escapes such as \n etc.
False to disallow parsing of escapes.
Default: false
allowVariables
True to allow parsing of variables such as $cat @cow etc.
False to disallow parsing of variables.
Default: false
allowCode
True to allow parsing of stuff inside { } and/or \C \c as physical Sputnik code.
False to disallow parsing of variables.
Default: false
Return Value
Success: Returns new string.
Failure: Returns empty string.
Remarks
None.
Example
println("Without Resolve: " . 'The value is $lol' ); println("With Resolve: " . ResolveStr('The value is $lol', true, true, true) );