-
-
Save steveosoule/78f575e5c304dc8720a5 to your computer and use it in GitHub Desktop.
MVT: MvCALL with JSON
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<mvt:comment>Define JSON holding variable</mvt:comment> | |
<mvt:assign name="l.settings:json" value="''" /> | |
<mvt:comment>Define URL Variable</mvt:comment> | |
<mvt:assign name="g.url" value="'http://example.com/'" /> | |
<mvt:comment>Call `g.url` and Concatenate `s.callvalue` into `l.settings:json`</mvt:comment> | |
<mvt:call action="g.url" method="'GET'"> | |
<mvt:assign name="l.settings:json" value="l.settings:json $ s.callvalue" /> | |
</mvt:call> | |
<mvt:comment>Parse JSON -> Miva Array Structure</mvt:comment> | |
<mvt:assign name="l.success" value="miva_json_decode( l.settings:json, l.settings:miva_structure_variable )" /> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment