Support » Plugin: jQuery UI Widgets » its frustrating, cant get it working at all

  • Hello,

    i installed the plugin. In plugin settings i added to Custom jQuery

    $( "#accordion" ).accordion();

    then to the not visual text tab in a page:

    <div id="accordion">
      <h3>First header</h3>
      <div>First content panel</div>
      <h3>Second header</h3>
      <div>Second content panel</div>
    </div>

    i tried to change id to class. Its displayed some how as formated text, partial bold. Please advice!

    https://wordpress.org/plugins/jquery-ui-widgets/

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author David Gwyer

    (@dgwyer)

    You need to wrap the jQuery code in a document ready function too. See the comments on the Plugin settings page.

    ok its

    jQuery(document).ready(function($) {
    <div id="accordion">
      <h3>First header</h3>
      <div>First content panel</div>
      <h3>Second header</h3>
      <div>Second content panel</div>
    </div>
    });

    still i dont have a clue how or where to place it in my “page”.
    do i have to add somthing like <script>?

    Plugin Author David Gwyer

    (@dgwyer)

    No, you wrap the jQuery code in Plugin settings in the document ready code not the HTML:

    jQuery(document).ready(function($) {
    $( "#accordion" ).accordion();
    });

    OK thanks for your answer. It works now.
    Is there any cirtical advice how to wrap a accordion into tabs?

    Plugin Author David Gwyer

    (@dgwyer)

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘its frustrating, cant get it working at all’ is closed to new replies.