show a category on the home page (index ?)
-
i’d like to show a specific category on my home page instead of the latest post (as shown in the quoted section).
How do i do that ?
please show me the complete code if possible, i’m a complete php noob.thanks.
This is my index.php code :
<?php get_header(); ?>
<div id=”side-left”>
<div id=”content”><?php if (have_posts()) : ?>
<?php while (have_posts()) : the_post(); ?>
<div class=”kutu”>
<div class=”ust”><span></span></div>
<div class=”post” id=”post-<?php the_ID(); ?>”>
<h2>” rel=”bookmark” title=”<?php the_title_attribute(); ?> i√?in Kal?±c?± Ba?ülant?±”><?php the_title(); ?></h2>
<div class=”tags”><?php the_tags(‘Tags: ‘, ‘, ‘, ”); ?></div><div class=”entry”>
<?php the_content(‘ ‘); ?>
</div>
<br class=”clear” />
<div class=”postmetadata”><?php edit_post_link(‘Edit’, ”, ‘ | ‘); ?> <?php the_time(‘d F Y’) ?> | <?php the_author_posts_link(‘namefl’); ?> | <?php the_category(‘, ‘) ?> | <?php comments_popup_link(‘No Comment’, ‘1 Comment’, ‘% Comments’); ?> | ” rel=”bookmark” title=”Permanent Link to <?php the_title(); ?>” class=”more”>Read More</div>
</div><div class=”alt”><span></span></div></div>
<?php endwhile; ?><div id=”navigation”>
<div class=”alignleft”><?php next_posts_link(‘Older Entries‘) ?></div>
<div class=”alignright”><?php previous_posts_link(‘Newer Entries‘) ?></div>
</div><?php else : ?>
<div class=”kutu”>
<div class=”ust”><span></span></div>
<h2 class=”center”>Not Found</h2>
<p class=”center”>Sorry, but you are looking for something that isn’t here.</p><div class=”alt”><span></span></div></div>
<?php endif; ?>
</div>
</div>
<?php get_sidebar(); ?>
<?php get_footer(); ?>
- The topic ‘show a category on the home page (index ?)’ is closed to new replies.