Search and Top Navigation
#8835 closed bug (notabug)
Opened November 20, 2012 02:05AM UTC
Closed November 20, 2012 02:07AM UTC
Last modified November 20, 2012 05:32AM UTC
_getPanelForTab bug when tabs has same id is nested.
Reported by: | bdh92123 | Owned by: | |
---|---|---|---|
Priority: | minor | Milestone: | 1.10.0 |
Component: | ui.tabs | Version: | 1.9.1 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
when the follow situation:
<div id="tab1">
<ul><li><a href="#panel1">Panel1</a></li></ul>
<div id="panel1">
<div id="nestedtab">
<ul><li><a href="#panel1">Nested Panel1</a></li></ul>
<div id="panel1">
</div>
</div>
</div>
</div>
,
line 11700 in _getPanelForTab function :
this.element.find( this._sanitizeSelector( "#" + id ) );
catches two 'panel1' div.
that line should be
this.element.find( this._sanitizeSelector( "#" + id ) ).eq(0);
Thanks for contributing. jQuery never has, but specifically removed, support for having two elements with the same id on a page. That's invalid markup. If you can reproduce this bug using valid HTML without duplicated id's, please submit a new bug report. Thanks again!