JQuery追加图像

时间:2015-11-16 22:52:40

标签: jquery squarespace

我正在尝试将缩略图移动到摘要标题下方。这是我的代码。目前没有任何反应有什么建议?谢谢!

JQuery的

 $(".summary-thumbnail-image" ).insertBefore( ".summary-excerpt" );

HTML

<div class="summary-item">
<a href="/blog/gathering" class="summary-thumbnail-container">
<div class="summary-thumbnail">
<img src="gathering.jpg" class="summary-thumbnail-image">
</div>
</a>

<div class="summary-title">...</div>

<div class="summary-excerpt">...</div></div>

2 个答案:

答案 0 :(得分:0)

尝试添加$(".summary-thumbnail-image" ).html().insertBefore( ".summary-excerpt" );

        For Each s In Sheets
            If s.Name Like printNames Then
                s.Select False
            End If
        Next s

        ActiveSheet.ExportAsFixedFormat Type:=xlTypePDF, Filename:= _
        path & filename & ".pdf", Quality:=xlQualityStandard, _
        IncludeDocProperties:=True, IgnorePrintAreas:=False, OpenAfterPublish:=True

答案 1 :(得分:0)

你可以尝试

$(document).ready(function(){
  $('.summary-item').each(function(){
     var ThisIt = $(this);
     ThisIt.find('.summary-thumbnail-container').insertAfter(ThisIt.find('.summary-title'));
  });
});