Bug Tracker

Ticket #5769 (closed bug: invalid)

Opened 5 years ago

Last modified 5 years ago

series of parent divs with display:none -- fail to hide

Reported by: ladybug Owned by:
Priority: major Milestone: 1.4
Component: effects Version: 1.3.2
Keywords: Cc:
Blocking: Blocked by:

Description

I have a series of divs - all have the class item_desc but have different ids. All have other divs and elements inside. All parents divs (class item_desc) are set to diplay:none except the first one which is set to diplay:block.

While the example code works in 1.3.1 it no longer works in latest 1.3.2 update. -- none of the recommended fixes work -- and seem to require major code acrobatics for what was once so easy to do.

Example:

JQuery

$(document).ready(function(){

$('.item_desc:not(:first)').hide(); $("#lcol a").click(function() {

var element = $(this);

$('.item_desc').slideUp("slow"); $($(element).attr("href")).slideDown("slow");

return false;

});

CSS

.item_desc{

width:760px; margin:0; padding:0;

}

XHTML

<div style="display: block;" id="div1" class="msg_body"> <div class ="someclass"> <p>content</p> <p>content</p> <ul> <li>list item</li> <li>list item</li> <li>list item</li> </ul>

</div>

</div>

<div style="display: none;" id="div2" class="msg_body"> <div class ="someclass"> <p>content</p> <p>content</p> <ul> <li>list item</li> <li>list item</li> <li>list item</li> </ul>

</div>

</div>

<div style="display: none;" id="div2" class="msg_body"> <div class ="someclass"> <p>content</p> <p>content</p> <ul> <li>list item</li> <li>list item</li> <li>list item</li> </ul>

</div>

Change History

comment:1 Changed 5 years ago by ladybug

Sorry --- initial bug input had wrong XHTML example.

<div style="display: block;" id="div1" class="item_desc"> <div class ="someclass"> <p>content</p> <p>content</p> <ul> <li>list item</li> <li>list item</li> <li>list item</li> </ul>

</div>

</div>

<div style="display: none;" id="div2" class="item_desc"> <div class ="someclass"> <p>content</p> <p>content</p> <ul> <li>list item</li> <li>list item</li> <li>list item</li> </ul>

</div>

</div>

<div style="display: none;" id="div3" class="item_desc"> <div class ="someclass"> <p>content</p> <p>content</p> <ul> <li>list item</li> <li>list item</li> <li>list item</li> </ul>

</div>

comment:2 Changed 5 years ago by dmethvin

  • Status changed from new to closed
  • Resolution set to invalid
  • Component changed from unfiled to fx

I'm not sure what the code here is supposed to demonstrate. Can you provide a clear test case?

Note: See TracTickets for help on using tickets.