- This topic has 15 replies, 5 voices, and was last updated 4 years ago by .
- You must be logged in to reply to this topic.
Tagged: Hide, Javascript, Premium Button, Show
Hello Abanob,
I have the same task: need to show (and hide) section on the button click. I thought I’ve repeated everything from the discussion above, but it does not work.
CSS ID of the target section is slide-6, CSS class is hidden-section. Section is hidden with css .hidden-section {display: none;}
I wrote document.getElementById("slide6").classList.toggle("show");
in onclick Event of premium button, and .show { display: block; }
in the page css.
When I click the button it does nothing.
Could you please advise what the problem can be? Thank you!
Hello Svitlana,
Hope you’re doing well today 🙂
Well, I think that this can be fixed simply by changing show
to hidden-section
in this line document.getElementById("slide6").classList.toggle("show");
to be document.getElementById("slide6").classList.toggle("hidden-section");
Thanks
Aya
Hello Aya Ali,
You are right, thank you! But also I had to replace double quotes with single and only now it works 🙂
I’m so glad that everything is working just fine with you now.
If you have any farther questions, please don’t hesitate to feed me back anytime 🙂
Also, it would be great if you could please do us a BIG favor ? if you could take 2 min of your time, we’d really appreciate if you give Premium Addons for Elementor 5-star rating on WordPress. By spreading the love, we can create even greater free stuff in the future!
Thanks,
Aya
This is working great for me!! thanks a lot.
Is there a way I can make the last shown elementor element hide when I click on another show button? This is so people can toggle through different options.
Many thanks for your help.
Hi James,
I’ve replied your ticket on our support system, so could you please check that from your end ?
Regards,
Abanob
Leap13 is a 5 Stars rated WordPress focused web development firm specialized in building Premium WordPress Themes and Plugins.
Enter your email and be the first to receive our latest news!
© 2024 Leap13 - Proudly Made by Wiz - The Smart Theme