Having no luck with
http://modx.com/extras/package/simplxwidgeteer
have created tpls for GR as the OpenGeek kindly recommended ;-)
{
"title":"[[*pagetitle]]",
"link":"[[~[[*id]]]]",
"description":"[[*description]]",
"language":"en",
"copyright":"",
"ttl":"",
"entries":[
[[!getResources:default=``?
&parents=`[[!switch?&get=`[[*context_key]]`&c1=`web`&do1=`22`&c2=`ned`&do2=`21`&c3=`rus`&do3=`20`&c4=`estonian`&do4=`19`&default=`22`]]`
&tpl=`tpl.JSON.Data`
&tplLast=`tpl.JSON.Data.last`
&depth=`2`
&hideContainers=`1`
&context=`[[!switch?&get=`[[*context_key]]`&c1=`web`&do1=`web`&c2=`ned`&do2=`ned`&c3=`rus`&do3=`rus`&c4=`estonian`&do4=`estonian`&default=`web`]]`
]]
]
}
where tpl.JSON.Data
is the chunk CODE:
{
"title":"[[+pagetitle]]",
"link":"[[~[[+id]]]]",
"date":"[[+pub_date]]",
"cout":"[[+unpub_date]]",
"guid":"[[+id]]",
"author":"",
"description":"[[+description]]",
"introtext":"[[+introtext]]",
},
======================================================================
tpl.JSON.Data.last is the last tpl chunk (which does not have a comma on the tail) CODE:
{
"title":"[[+pagetitle]]",
"link":"[[~[[+id]]]]",
"date":"[[+pub_date]]",
"cout":"[[+unpub_date]]",
"guid":"[[+id]]",
"author":"",
"description":"[[+description]]",
"introtext":"[[+introtext]]",
}
=========================================================================
So this returns resources in JSON format (I believe) ;-) and my JSON class can happily read it!
Hope it helps someone, cheers