介绍10条不管是修改还是制作wordpress主题可能需要用到的基本代码技巧.
1.不在首页显示某个分类下的文章.
就像鸭脖客的博客集一样,我想让他们单独呆在一个新建的页面,而不同时在首页显示,就需要用到以下代码来排除首页文章列表中的分类.
[sourcecode language='php']
the_post();
if (is_home()) if (in_category('需要隐藏的分类ID')) continue;
?>
[/sourcecode]
2.在边栏或其他位置只显示某一分类下的文章. [/sourcecode] 然后在css里添加
[sourcecode language='php']
user_id == 1) $oddcomment = “authorcomment”; echo $oddcomment; ?>”>
[sourcecode language='css']
.authorcomment { background-color: #555 !important; }
[/sourcecode]
Eventually, the company realized that the name Ask! ,
Cities can charge whatever fees they please. ,
你好,我对这个http://equilibrium.madebyon.com/installation/操作不是很明白,您能不能帮个忙给我讲解一下呀?
我该如何做才能像他的演示一样显示主页的图片?我现在就是这个问题
简单说,按步骤,做什么,多谢了