json.fromStrProp: Difference between revisions

From RPTools Wiki
Jump to navigation Jump to search
m (Conversion script moved page json.fromStrProp to Json.fromStrProp without leaving a redirect: Converting page title to first-letter uppercase)
No edit summary
 
(2 intermediate revisions by 2 users not shown)
Line 6: Line 6:


|usage=
|usage=
<source lang="mtmacro" line>
<syntaxhighlight lang="mtmacro" line>
json.fromStrProp(propList)
json.fromStrProp(propList)
json.fromStrProp(propList,delim)
json.fromStrProp(propList,delim)
</source>
</syntaxhighlight>
'''Parameters'''
'''Parameters'''
{{param|propList|String property list to extract data from.}}  
{{param|propList|String property list to extract data from.}}  
Line 15: Line 15:


|example=
|example=
<source lang="mtmacro" line>
<syntaxhighlight lang="mtmacro" line>
[r:json.fromStrProp("a=1;b=44;c=12")]
[r:json.fromStrProp("a=1;b=44;c=12")]
</source>
</syntaxhighlight>


Returns
Returns

Latest revision as of 23:59, 15 March 2023

json.fromStrProp() Function

Introduced in version 1.3b49

Usage

json.fromStrProp(propList)
json.fromStrProp(propList,delim)

Parameters

  • propList - String property list to extract data from.
  • delim - Delimiter between fields (default is ";").

Example

[r:json.fromStrProp("a=1;b=44;c=12")]

Returns

{"a":1,"c":12,"b":44}