API: betaalbareapps.nl: GET-array

API: http://betaalbareapps.nl/manager/api.php?applicatieID=47507&entiteitID=47529&type=getobjects&filter%5Bpostcode%5D=9321vl
This API-URL is something like “…&filter[postcode]=9…” is a special, I call it “GET-array”, way of send data. As of PRO-version 3.3.3 this can be handled in this way:

Shortcode:

[jsoncontentimporterpro parser=twig url=http://betaalbareapps.nl/manager/api.php?applicatieID=47507&entiteitID=47529&type=getobjects&filter%5Bpostcode%5D=9321vl id=TEMPLATE_MANAGER_ID urlparam=filter%5Bpostcode%5D#test]

By “urlparam=filter%5Bpostcode%5D#test” you enable the plugin to accept “http://…?…&test=SOMETHING&filter[postcode]=ANOTHER_SOMETHING” and transfer this to the twig-template engine.


twig-Code:

<form action="/api-betaalbareapps-nl/">
Number of Plate: <input type=text name="filter[postcode]" id=postcode value="" placeholder="default value is 9321vl">
<input type=submit value="do search"></form>

{{message}}
{% for r in result %}
{{r.datum_aangemaakt | date("d.m.Y, H:i") }}: 
objectID is {{r.objectID}}
{% endfor %}

Example:
Number of Plate:
1 resultaat gevonden. 23.01.2017, 16:17: objectID is 48338