In an earlier post Bruno17 suggested using
[[!getPage?
&element=`migxLoopCollection`
&packageName=`clients`
&classname=`Request`
&where=`{"type:=":"2"}`
&tpl=`tplRequest`
&wrapperTpl=`tplRequestOuter`
&limit = `5`
&debug=`0`
]]
[[!+page.nav]]
I am trying to understand how to do the same using this snippet from my post earlier this week.
[[migxLoopCollection?
&classname=`modUserProfile`
&joins=`[{"alias":"Data","classname":"userData","on":"Data.userdata_id=modUserProfile.internalKey"}]`
&where=`{"modUserProfile.state":"AB"}`
&tpl=`UsersProvTpl`
]]
I suspect my problem lies with handling the "&joins".
Any suggestions will be most welcome
Thanks Jim
Give a man the answer, and he’ll only have a temporary solution. Teach him the principles that led you to that answer, and he will be able to create his own solutions in the future.
doesn't this work?
[[!getPage?
&element=`migxLoopCollection`
&classname=`modUserProfile`
&joins=`[{"alias":"Data","classname":"userData","on":"Data.userdata_id=modUserProfile.internalKey"}]`
&where=`{"modUserProfile.state":"AB"}`
&tpl=`UsersProvTpl`
&limit=`5`
]]
[[!+page.nav]]
Thanks Bruno, that did it. No sure why it wouldn't work before but I also reinstalled getPage.
Give a man the answer, and he’ll only have a temporary solution. Teach him the principles that led you to that answer, and he will be able to create his own solutions in the future.