如何使用小工具制作友情链接?
<div id="sidebarBox">
<div class="boxTop">
<h2>友情链接</h2>
</div>
<div class="boxContent">
<ul class="linksTxt">
<li><a rel='nofollow' href='http://www.wordpresss.cn/xxx' target='_blank'>xxx</a> </li>
<li><a rel='nofollow' href='http://www.wordpresss.cn/qqq' target='_blank'>qqq</a> </li>
<li><a rel='nofollow' href='http://www.wordpresss.cn/aaa' target='_blank'>aaa</a> </li>
<li><a rel='nofollow' href='http://www.wordpresss.cn/ddd' target='_blank'>ddd</a> </li>
...
</ul>
</div>
</div>
上面是html源代码这里想用小工具来制作友链,functions.php部分代码:
$args = array(sidebar.php部分代码:
'name' => '首页侧栏',
'description' => '网站首页侧栏',
'class' => '',
'before_widget' => '<div class="boxTop"><h2>友情链接</h2>',
'after_widget' => '</div>',
'before_title' => '<div class="boxContent"><ul class="linksTxt">',
'after_title' => '</ul></div>'
);
register_sidebar( $args );
<div id="sidebarBox">不管怎么样去调试,貌似都搞不掂。怎么样才能向HTML源码那样呢?
<?php
if(!dynamic_sidebar('首页侧栏'));
?>
</div>
1 个回复
cunyanr
赞同来自:
寸言博客 cunyanr.cn