
In order to get a list of certain categories of posts in a side bar to add to the menu right place the following code:
‘cat=2&showposts=5′ ) ; ?> <? php query_posts ( 'cat = 2 & showposts = 5');?>
<ul>
( have_posts ( ) ) : the_post ( ) ; ?> <? php while (have_posts ()): the_post ();?> <li> <a href = "<? php the_permalink ()?>">
; ?></a></li> <? php the_title ();?> </ a> </ li>
;?> <? php endwhile;?> </ ul>
This code assumes that the side bar will display the last five posts from the category with id = 2. These settings can be changed. More information is available, where I got this, namely, in a blog on WordPress from Taras.
Popularity: 25%
Under section Novoeyplovsky tramp, I koplyu on the Mac.
At this point in my possession is 34 000 rubles.
![]() | ![]() | |||||||||||||||||||||
Leave a reply