
I wanted to just show my ‘website news’ category in the root of my Wordpress installation. But by default index.php shows the latest posts from all categories, this was not what I wanted. So how could I get what I want?
Step 1
I take a look in index.php. It displays:
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:

