2012-11-08 23 views
0

我試圖做一個div,我打電話給發佈縮略圖,以識別flexcroll,但它不工作。它適用於文本,但不能以這種方式:如何使flexcroll與WordPress的後期縮略圖一起工作?

<div class="post"> 
<?php query_posts('p=77'); 
while (have_posts()) : the_post();?> 
<div id="contcell" class="flexcroll"> 
<div id="thumb" ><?php echo get_the_post_thumbnail($post->ID, 'full'); ?></div></div> 
<?php endwhile; ?> 
<?php wp_reset_query(); ?> 
</div> 

而這些都是相關的CSS:

#contcell {width:1116px; height:300px; overflow:auto;} 
.thumb {width:1116px; height:768px;} 

如果我禁用flexcroll類,瀏覽器默認的滾動條的作品。 任何想法? Thx提前。

回答

0

解決了它。這不是在flexcroll div中加載什麼內容,而是清除其內容的浮動。發現它在flexcroll用戶指南例子:

<div id='mycustomscroll' class='flexcroll'> 

<img src="mypicture.jpg" width="100" height="100" class="floated" /> 

<img src="mypicture.jpg" width="100" height="100" class="floated" /> 

<img src="mypicture.jpg" width="100" height="100" class="floated" /> 

<img src="mypicture.jpg" width="100" height="100" class="floated" /> 

<!-- we clear our floats using the following div, check out the CSS for it--> 

<div class="clearfloat"></div> 

</div> 

而CSS:

.clearfloat { 
clear:both; height:0px; 
line-height:0px; visibility: hidden; 
} 

這是所有的代碼下載文件夾內。不知道我是否可以在這裏直接鏈接,但很容易找到它。希望它能幫助別人。