修复了chrome浏览器中的兼容性bug
This commit is contained in:
parent
5ab5e4f2ef
commit
3cbdd0bf71
|
@ -50,18 +50,12 @@ setTimeout("document.getElementsByClassName('box-info').remove(0)",5000);
|
|||
|
||||
</div>
|
||||
<script>
|
||||
function loadmasonry(){
|
||||
em = document.getElementsByClassName('thumb');
|
||||
for(var i=em.length-1;i>=0;i--){
|
||||
var p = em[i];
|
||||
if(p.width < 1)
|
||||
{
|
||||
var timer = setTimeout("loadmasonry()",100);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
$('#container').masonry({itemSelector: '.items',columnWidth : 210 });
|
||||
}
|
||||
loadmasonry();
|
||||
var $tumblelog = $('#container');
|
||||
$tumblelog.imagesLoaded(function(){
|
||||
$tumblelog.masonry({
|
||||
itemSelector: '.items',
|
||||
columnWidth: 240
|
||||
});
|
||||
});
|
||||
$(".items").mouseover(function(){$(this).addClass("hover")}).mouseout(function(){$(this).removeClass("hover")})
|
||||
</script>
|
Loading…
Reference in New Issue