简体   繁体   中英

JQuery tabs doesn't work - no error

This is what I have included:

  <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
  <script src="http://code.jquery.com/ui/1.11.2/jquery-ui.js"></script>

  <script src="http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/js/bootstrap.min.js"></script>
  <link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css">

  <script src="tabs.js"></script>

This is in my html:

            <div id="#tabs">
                <ul class="nav nav-tabs">
                    <li><a href="#tab1">Informationen</a></li>
                    <li><a href="#tab2">Kontakten</a></li>
                    <li><a href="#tab3">Nachrichten</a></li>
                    <li><a href="#tab4">Messages</a></li>
                </ul>
                <div id="tab1">dsds</div>
                <div id="tab2">dsds</div>
                <div id="tab3">dsds</div>
                <div id="tab4">dsds</div>
            </div>

and this is in tabs.js:

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

After page loading there is no error, all files are found, but jQuery tabs do absolutely nothing and all divs are visible. It is the simplest example of tabs, what is wrong here?

<div id="tabs">更改<div id="#tabs"> <div id="tabs">

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM