Answer the question
In order to leave comments, you need to log in
[[+content_image]]
How to pass the value of the Extra field (TV) in pdoResources to the &resources value?
I need the person in TV to indicate the id of the entry separated by commas and that this id be passed to pdoResources as the &resources value.
[[pdoResources?
&parents=`0`
&depth=`0`
&includeTVs = `revel-post_manual`
&processTVs = `revel-post_manual`
&resources=`[[*revel-post_manual]]`
&limit=`5`
&tpl=`relev_post_tpl`
&useWeblinkUrl=`1`
&sortby=`RAND()`
&tplCondition=`template`
&tplOperator=`==`
&conditionalTpls=`{"14":"fourth_level"}`
]]
Answer the question
In order to leave comments, you need to log in
Make the TV revel-post_manual type "Multiple choice", in the "Possible values" write:
@EVAL return $modx->runSnippet('pdoResources',array(
'parents'=>5, // ID контейнера откуда получать варианты для выбора
'limit'=>0,
'sortby'=>'{ "pagetitle":"ASC" }',
'tpl'=>'@INLINE [[+pagetitle]] (87685)==87685',
'outputSeparator'=>'||'
));
[[pdoResources?
&resources=`999999999`
//.......
]]
You need to carefully look at the name of the parameters
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question