我有一个小提琴,当转移现场不是很好。 http://jsfiddle.net/q9cfa6qu/11/
在我的小提琴中,状态是在列中,但是当它们实时转移时它们就成了行!与代码没有区别。
Woring jfiddle:http://jsfiddle.net/q9cfa6qu/11/
破碎的小提琴:http://unclestevesny.com/test-accordion-2/ [直播] http://screencast.com/t/Hu41l12ugS
这是HTML。 html,css和jquery与我的jfiddle完全相同。
<div id="storecontainer">
<div class="element_content_header_3">Find a Store</div>
<div class="accordion">
<h2>New York</h2>
<div class="pane">
<div class="accordion accordion2">
<h2><img src="http://unclestevesny.com/wp-content/uploads/2014/10/Whole-Foods-Market-Logoa.png" alt="Whole Foods Market" /></h2>
<div class="pane">
<div class="oestlstore">
Market 97th St<br />
808 Columbus Ave.<br />
New York, NY 10025
</div>
<div class="oestlstore">
Columbus Circle 10 <br />Columbus Circle <br />New York, NY 10019
</div>
<div class="oestlstore">
Manhasset <br />2101 Northern Blvd.<br />New York, NY 11030
</div>
<div class="oestlstore">
Union Square <br />4 Union Square South<br />New York, NY 10003
</div>
</div>
<h2 ><img src="http://unclestevesny.com/wp-content/uploads/2014/10/stopshopicon.jpg" alt="Stop & Shop" style="margin-top:10px;" /></h2>
<div class="pane">
test
</div>
<h2><img src="http://unclestevesny.com/wp-content/uploads/2014/10/ShopRiteicon.png" alt="ShopRite" /></h2>
<div class="pane">
test
</div>
</div>
</div>
<h2>New Jersey</h2>
<div class="pane">
content
</div>
<h2>California</h2>
<div class="pane">
content
</div>
<h2>District of Columbia</h2>
<div class="pane">
content
</div>
</div>
</div>
答案 0 :(得分:1)
在您网站的CSS中,您有:
h1, h2, h3, h4, h5, h6 {
clear: both;
line-height: 1.3;
}
你需要它们不要清除,所以添加
.accordion h1, .accordion h2, etc...
{
clear: none;
}