• Resolved grungyape

    (@grungyape)


    Looking for a way to mark a tab the default tab to open without having to make it my first tab….

    For example: https://www.screencast.com/t/cHCryIsu1

    I see no checkbox or marker in the settings to allow this. Can this be added, so that by default the first tab opens unless you mark a different tab as the default?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Contributor Gregor Capuder

    (@capuderg)

    Hi,

    there is no option like that in the plugin, however you could trigger a click on the tab you want to be opened by default with some custom JS/jQuery code on the page ready event. The click code would looks something like this:

    
    <script>
    jQuery( document ).ready( function() {
      jQuery( '.pt-tabs a[href="#tab-massage"]' ).click();
    } );
    </script>
    

    where the ‘#tab-massage’ is the tab you want to have opened by default.

    Add the above code to a normal *Text* widget and place that widget under the tabs widget in the page builder editor.

    Take care!

    Thread Starter grungyape

    (@grungyape)

    Pure genius right there, thank you.

    I will still suggest you consider this as a feature, but for now, problem solved.

    Plugin Contributor Gregor Capuder

    (@capuderg)

    Hi,

    no problem 🙂

    Thanks for the suggestion, I’ll consider it, when I’ll update the plugin.

    Take care!

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Default Tab’ is closed to new replies.