Forums

CFv5: Enable disable containers

hennysmafter 27 Nov, 2014
Dear developers and users,

When I look at the demo: demo-fields-events
It shows how to hide and show certain fields. Which is excellent.

But I want to create the following:

Question Yes(show container 1) / No(show container 2)

Container1:
Custom Code(some basic HTML image and text)
Dropdown
Textfields etc.

Container2:
Custom Code(some basic HTML image and text) (different from con. 1)
Dropdown
Textfields etc.


I got the idea working with the Question and both drop downs. But the custom code sections are both showing the entire time. Therefore I would like to know how to hide the container and not the fields. Because I can't assign an ID to Custom Code.

Thanks for helping.
hennysmafter 27 Nov, 2014
PS: I was forgotton to add the Joomla Version. Which is the latest J 3.3.6
hennysmafter 27 Nov, 2014
I found out that to hide custom code is easy. Start the code with for example a div and use the id that you want to hide in this div. Now add everything you want to write inside this div and you are finished.

Code Example:

<div id="THEIDUSEDFORHIDINGANDSHOWING">fill in here all html code you want and close it with </div>


But now the next item how to hide an entire container so that you do not have to set the id on every element but only the container. I already tried by using this DIV id function inside start container and in end container </div> but this was not working.

Thanks for all responses in advance..
Max_admin 28 Nov, 2014
Answer
Hi hennysmafter,

Do you have the latest update ? the container should have a "load state" and normally you should also be able to hide any container of type "div" or "panel"..etc, as long as you use its "id".

Regards,
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
This topic is locked and no more replies can be posted.