Recent news box on front page for Tiga 1.0.2 theme (obsoleted)

Note: This blog article has been superseded by the article at http://www.learncpp.com/?p=30.

I added a “recent news” box to the front page of the site, which shows the most recent items posted in the News category. It’s the easiest way to find the most up to date news about the site or the C++ Tutorial.


For you Tiga fans who would like to add your own recent posts box to your Tiga-themed web site, here’s how you do it.

  1. First, install the customizable post listings plugin. This plugin is what does the work of listing the posts.
  2. Second, download the newspage page template and extract it to a local directory. This newspage page template will only work with the Tiga theme.
  3. Third, edit the newspage.php file with an editor (for Windows users, wordpad works fine). You will see a line that looks like this: <ul><?php c2c_get_recent_posts(5, "<li>%post_date%: %post_URL%</li>", "4"); ?></ul>

Change the “4” to the category ID of the category you want the box to display posts from. If you want the box to display posts from multiple categories, change the “4” to a space separated list of category IDs.

  1. Upload the template into your wp-content/themes/tiga-06/ directory.
  2. Go to your WordPress Administrator. For each page you wish to have a recent posts box: Edit the page. On the right side, you should see a “Page Template” box. Select “Newspage”. Save your page.

That’s it.

guest
Your email address will not be displayed
Avatars from https://gravatar.com/ are connected to your provided email address.
Notify me about replies:  
0 Comments
Inline Feedbacks
View all comments