Step 1
I take a look in index.php. It displays:
<?php
/* Short and sweet */
define("WP_USE_THEMES", true);
require("./wp-blog-header.php");
?>
Step 2
After looking at this code I could see, clearly, there was no statement to restrict what category to show, which was what I wanted. So I checked in the Administration>Categories section in the Administration part of my site to find out the category ID of the category I wanted to just show on my index.php in my Wordpress installation root, the category ID was ‘2?. I changed index.php to the following and uploaded it to my webserver:
<?php
$blog = 1;
if (!isset($cat)) {
$cat = "2";
}
/* Don't remove this line. */
define("WP_USE_THEMES", true);
require("./wp-blog-header.php");
?>
5:44 pm - 9-18-2006
Another alternative is to make a “home.php” file in your themes directory, which contains the contents of your “index.php” file. Then, you can just filter the category like so:
If you don’t like the idea of all that duplication between “index.php” and “home.php”, you could just wrap things up in an IF statement checking if (is_home()).
5:47 pm - 9-18-2006
Ahem… Like so:
query_posts(’cat=1′); while ( have_posts() ) : the_post()