ElementorElementor Tips & TricksWordpressWordpress Tips & Tricks

How To Close By Default The Elementor Accordion

How To Close Accordions By Default In Elementor

How do you keep the accordion closed by default Elementor? The question that has probably thought about many times and you have never found the answer.

elementor accordion default closed done by some technics such as use the Toggle widget.  However, if you want to use a way that works in the end, you have to look for the most practical technique.

Our goal in this content is to introduce all the ways of Elementor accordion closed by default and help you choose the best way.

What Is Accordion In Elementor?

The accordion is a widget in the Elementor plugin, which can be used to show the content in collapsed way. This widget designed to facilitate access to information for users as well as to minimize the space occupied.

With this widget, you can show the titles in a categorized form to users could develop any of them as they wishes. WordPress sites automatically enable this feature. However, as a WordPress site designer, you may not want the accordion open by default.

Fortunately, this problem has many solutions, the following of which we will learn with the most convenient ones.

3 Ways To Elementor Accordion Default Closed

You can use one of this technics to close accordions by default in Elementor:

Write Code

In this way, you just need to enter the following code to close accordion by default:

<script>

jQuery(document).ready(function($) {

var delay = 100; setTimeout(function() {

$(‘.elementor-tab-title’).removeClass(‘elementor-active’);

$(‘.elementor-tab-content’).css(‘display’, ‘none’); }, delay);

});

</script>

This question also arises for many WordPress users:

How to make the Elementor accordion close only on mobile?

Well, the answer to this question is the following code.

<script>

if(window.outerWidth < 425) {

alert(‘jQuery(document).ready(function($) {

var delay = 100; setTimeout(function() {

$(‘.elementor-tab-title’).removeClass(‘elementor-active’);

$(‘.elementor-tab-content’).css(‘display’, ‘none’); }, delay);

}); ‘);

}

Use The Divi Booster Plugin

 Divi Booster Plugin

Using a variety of plugins to change the default settings of WordPress sites is an efficient action. As this plugin helps you to elementor accordion start closed. Just follow the steps below after installing it:

  • install and active the Divi Booster plugin
  • go to “Accordion Module Settings” part
  • click the “design” option
  • now click the “Toggle” option
  • then click ” Initial State” option
  • then choose the “all closed” option

Use The PowerPack Addons Plugin

PowerPack Addons plugin

another plugin that will help you in this way is “PowerPack Addons”.  Using this plugin, just follow the steps below in order:

  • Install the PowerPack Addons for Elementor plugin. And then active that.
  • Consider the page on which you want the Accordion widget to be placed. Then edit this page with Elementor.
  • Now it is time to use the Advanced Accordion widget. You can see this widget from the PowerPack Elements group. So, drag and drop that.
  • In this step, all Accordion panels are closed by default in the Advanced Accordion widget of PowerPack plugin. Therefore, you can write the content for that. Note that you need to save the actions.

Related Articles

2 Comments

Leave a Reply

Your email address will not be published.

Check Also
Close
Back to top button