wordpress实现仅显示某一分类下的文章上一篇下一篇代码

<style>
#nav-single { float:left; width:638px; margin:30px 0 0 0; font-size:12px; padding:20px 0 0 0; border-top:1px dotted #ccc; color:#777; }
.nav-previous { float:left; width:300px; overflow:hidden; }
.nav-next { float:right; width:300px; overflow:hidden; text-align:right; }
</style>

<!– 原来的,所有分类文章
<div id=”nav-single”>
<span><?php previous_post(‘%’, ‘上一篇:’, ‘yes’); ?></span>
<span><?php next_post(‘%’, ‘下一篇:’, ‘yes’); ?></span>
</div>
–>

<div id=”nav-single”>
<span><?php previous_post_link($format=’<strong>上一篇: </strong> %link’, $link=’%title’, $in_same_cat = true, $excluded_categories = ”) ?></span>
<span><?php next_post_link($format=’<strong>下一篇: </strong> %link’, $link=’%title’, $in_same_cat = true, $excluded_categories = ”) ?></span>
</div>

重设wordpress用户密码

使用步骤

1. 在 Village Idiot WordPress Emergency Password Script上下载Emergency Password Script脚本

2. 解压下载的压缩文件

3. 将emergency.php文件上传到WordPress根目录下(wp-config.php文件所在目录)

4. 在浏览器中打开http://example.com/emergency.php

5. 根据页面上的指示输入管理员用户名(通常为admin)与新密码,然后点击更新选项。之后会有消息显示密码更新成功。一封含有密码变更信息的邮件被发送到博客管理员的邮箱账号。

6. 完成后从服务器中删除emergency.php文件,不要将该文件留在服务器中,以免其他人用它来修改你的密码。

Pages: 1 2 Next