Problems, need help? Have a tip or advice? Post it here.
4 posts Page 1 of 1
Hello,

I have a custom field called team and I am feeding a pages command a comma seperated list of teamnames and it's mostly working as expected, except it does not work for teams with an ampersand in them (they just get ignored, other team pages are still returned.

This is the actual pages tag I am using and it is working except it does not return team pages where the teamname has an ampersand in them:

Code: Select all
<cms:pages masterpage='formular.php' custom_field="erl!=='ok' | team==<cms:show teamliste /> | internesdatum > <cms:show cutoffdate />" limit='100000' >


I tried to debug it by using one of the teams by name, so team=='Conferencing & Support' --> does not work. There are several existing pages where the team field does have this exact entry.

I also tried escaping like team=='Conferencing \& Support' but that doesn't work either. Any ideas?
Have you tried an substitute as a workaround?

https://unicode-table.com/de/0026/
Huh &amp; is actually working, so team=='Conferencing &amp; Support' does it. Thanks!
I think that is because Couch sanitizes ampersands to make them '&amp;' - please confirm this by outputting one such field's value on a page and then doing a view-source to look at the actual value. Perhaps using that value for ampersand would help in the search?
4 posts Page 1 of 1
cron