在首页输出博文的摘要,包含缩略图。
<b:includable id='postSnippet' var='post'>
<!-- 输出博文首张图片-->
<b:if cond='data:post.firstImageUrl'>
<div class='thumbnail-container'>
<img expr:alt='data:post.title' expr:src='data:post.firstImageUrl' expr:title='data:post.title'/>
</div>
</b:if>
<!-- 博文摘要 -->
<data:post.snippet/>
<div style='clear: both;'/> <!-- clear for photos floats -->
<!-- 跳转到博文详细页 -->
<div class='jump-link'>
<a expr:href='data:post.url + "#more"' expr:title='data:post.title'><data:post.jumpText/></a>
</div>
</b:includable>在 main includable 模块中引用。
<b:if cond='data:blog.url == data:blog.homepageUrl'>
<b:include data='post' name='postSnippet'/>
<b:else/>
<data:post.body/>
<div style='clear: both;'/> <!-- clear for photos floats -->
</b:if>