Blog-in-blog插件

今天给大家介绍一款BLOG-IN-BLOG插件,它可以实现用页面来展示某个目录下的文章列表,而且插件还提供了调用模板,用得相当方便,在此介绍一下如何修改调用特色图像。

bib

默认模板如下所示,见注释

<!-- fragment of html for post template. This file will be deprecated... -->
<!-- blog-in-blog Version: %bib_version% -->
<div><!-- Post Headline -->
<div><!-- 下面这行是获取文章作者的AVATAR头像并浮动显示在文章列表左侧 -->
<div style="float: left; margin: 7px;">%post_author_avatar%</div>
<h2><a id="%post_id%" title="Permanent Link to %post_title%" href="%post_permalink%" rel="bookmark">%post_title%</a></h2>
<!-- 下面这行是显示作者,日期时间和文章所在目录,建议删除 -->
<small>%post_author% : %post_date% %post_time% : %post_categories%</small></div>
<!-- Post Body Copy -->
<div>%post_content%</div>
<!-- 下面这行是显示评论数,建议删除 -->
<div>%post_comments%</div>
</div>

那接下来替换掉作者头像的代码,用特色图像,得到如下的代码,测试结果是完全OK的。

<!-- fragment of html for post template. This file will be deprecated... -->
<!-- blog-in-blog Version: %bib_version% -->
<div><!-- Post Headline -->
<div>
<div style="float: left; margin: 0 7px 0 0;"><a title="Permanent Link to %post_title%" href="%post_permalink%" rel="bookmark">%post_thumbnail%</a></div>
<h2><a id="%post_id%" title="Permanent Link to %post_title%" href="%post_permalink%" rel="bookmark">%post_title%</a></h2>
</div>
<!-- Post Body Copy -->
<div>%post_content%</div>
</div>

实例见这个网站的产品页:http://www.profound-hydraulics.com/products/denison-pumps/

“Blog-in-blog插件”的2个回复

发表回复

您的电子邮箱地址不会被公开。 必填项已用*标注