Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bootstrap-tabs.js doesn't work with complex href. #740

Closed
KendallHopkins opened this issue Dec 1, 2011 · 3 comments
Closed

Bootstrap-tabs.js doesn't work with complex href. #740

KendallHopkins opened this issue Dec 1, 2011 · 3 comments

Comments

@KendallHopkins
Copy link

I've found some href that are identical to #*id*, but don't work due to the way the javascript is implemented.

Example #1: href contains absolute path to self.

<ul class="tabs" data-tabs="tabs">
    <li  class="active" ><a href="/bootstrap/demo#home"><span>Home</span></a></li>
</ul>
<div class="tab-content">
    <div id="home" class="active">
        <p>Raw denim you probably haven't heard of them jean shorts Austin. Nesciunt tofu stumptown aliqua, retro synth master cleanse. Mustache cliche tempor, williamsburg carles vegan helvetica. Reprehenderit butcher retro keffiyeh dreamcatcher synth. Cosby sweater eu banh mi, qui irure terry richardson ex squid. Aliquip placeat salvia cillum iphone. Seitan aliquip quis cardigan american apparel, butcher voluptate nisi qui.</p>
    </div>
</div>

Example #2: href contains relative path to self.

<ul class="tabs" data-tabs="tabs">
    <li  class="active" ><a href="demo#home"><span>Home</span></a></li>
</ul>
<div class="tab-content">
    <div id="home" class="active">
        <p>Raw denim you probably haven't heard of them jean shorts Austin. Nesciunt tofu stumptown aliqua, retro synth master cleanse. Mustache cliche tempor, williamsburg carles vegan helvetica. Reprehenderit butcher retro keffiyeh dreamcatcher synth. Cosby sweater eu banh mi, qui irure terry richardson ex squid. Aliquip placeat salvia cillum iphone. Seitan aliquip quis cardigan american apparel, butcher voluptate nisi qui.</p>
    </div>
</div>
@fat
Copy link
Member

fat commented Dec 1, 2011

that is correct - you have to provide only a target id.

@fat fat closed this as completed Dec 1, 2011
@fat
Copy link
Member

fat commented Dec 1, 2011

in 2.0 you'll be able to optionally supply a data-target

@KendallHopkins
Copy link
Author

Good stuff. That sounds like a nice solution.

daveobriencouk pushed a commit to egocreative/bootstrap that referenced this issue Nov 18, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants