My hack for custom post types

I have custom post types setup on my school's website. I only wanted news-item post types on the main page. If you are running custom post types this plugin will not work. Here's my solution. You have to make three edits. My custom post type is: news-item

Around line 97, you will see
$query = "SELECT * FROM " . $wpdb->base_prefix . "site_posts WHERE blog_public = '1' AND post_type ='" . $recentglobalpoststype . "' ORDER BY post_published_stamp DESC LIMIT " . $recentglobalpostsnumber;

Inline, remove and add the custom post type by deleting " . $recentglobalpoststype . " and replacing it with news-item. It should look like:

$query = "SELECT * FROM " . $wpdb->base_prefix . "site_posts WHERE blog_public = '1' AND post_type ='news-item' ORDER BY post_published_stamp DESC LIMIT " . $recentglobalpostsnumber;

Around line 139, change:

'post_type' => 'post'

to

'post_type' => 'news-item'

Make that same change around line 162:

'post_type' => 'post'

to

'post_type' => 'news-item'

I hope that helps. :slight_smile: You can see the plugin in action at http://www.RiversidePrep.net