Search the FirstSpirit Knowledge Base
Good morning community,
For our bootstrap 4 based project i have several sectiontemplates with a <FS_CATALOG input and the editor can use standard templates like headline or text in that.
Our text templates have <CMS_INPUT_TOGGLE switches to activate several options around the actual html element.
If the template is used in an <FS_CATALOG field, the toggles should all be set to false and hidden, because in that case it should not be possible to set these options.
Unfortunately i am not able to write the correct <RULE to do so. Hiding is possible but setting the value is my problem.
<WITH>
<EQUAL>
<PROPERTY name="CONTAINERTYPE" source="#global"/>
<TEXT>FS_CATALOG</TEXT>
</EQUAL>
</WITH>
<DO>
<NOT>
<PROPERTY name="VISIBLE" source="st_containerstart"/>
<PROPERTY name="VISIBLE" source="st_containerend"/>
<PROPERTY name="VISIBLE" source="st_rowstart"/>
<PROPERTY name="VISIBLE" source="st_rowend"/>
</NOT>
</DO>
</RULE>
Please Help
Thanks
Christoph
Hi Christoph,
I assume, you already tried setting the value property on the respective toggle gadgets within the DO section? If so, do you get any ERROR, WARN, or DEBUG messages in the log file that refer to not working rules?
Cheers,
Stefan
Correct, i was setting the VALUE like THIS:
<NOT> | |||
<PROPERTY name="VALUE" source="st_containerstart"/> | |||
<PROPERTY name="VALUE" source="st_containerend"/> | |||
<PROPERTY name="VALUE" source="st_rowstart"/> | |||
<PROPERTY name="VALUE" source="st_rowend"/> | |||
</NOT> |
This results in a switch to NO/false on the User interface but in the output with
$CMS_IF(st_containerstart == true)$<div id="container_$CMS_VALUE(#global.section.id)$" class="container">$CMS_END_IF$
it is true and shows the <div in the html output. (which is the opposite from the expected behaviour)
Did you check the value of st_containerstart itself via CMS_VALUE? Just to make sure.
Hello Christoph,
is this still an open question? Do you need further help or did the given answers already help you? In this case it would be nice if you mark the "right answer".
Best regards
Michaela