Home » Experts Only » Add YARPP to Custom Post Types: WordPress

Add YARPP to Custom Post Types: WordPress

A great little plugin for adding related posts to your blog has been around for a while: YARPP, Yet Another Related Posts Plugin. It’s fairly robust, for being free, but it does not natively support custom post types – a bummer.

A quick way around this is to add a simple piece of code in your functions.php file.

add_filter('wpcf_type', 'yarpp_support_func', 10, 2);
function yarpp_support_func($data, $post_type)
{
 if(in_array($post_type, array(
 'your-custom-post-type',
 )))
 {
 $data['yarpp_support'] = true;
 }
 return $data;
}

This is a handy little solution. Simply replace ‘your-custom-post-type’ with the slug of your CPT and you’re in business. Now related posts show up just fine and you can take advantage of all the great things YARPP has to offer! Custom programming has never been easier with WordPress.

More Web Design Blog Content

Website To Text

Introducing the Livewire Website to Text Application, a cutting-edge tool that transforms consumer engagement. Imagine having the ability to instantly connect with customers in a personalized way, bridging the gap between your website visitors and your company with ease. With this game-changing feature, you gain access to a plethora

New Website: Top Dawg Detection

Bed bug detection is a fascinating new business. Trained in a facility up north, these dogs are trained to detect even a single bed bug. Most of the business is certifying hotels and motels as “bed bug free”. These dogs are about 97% accurate and are fun to

The Brief Business Guide To Instagram

Instagram is a misunderstood product for most business owners. Isn’t facebook enough? No. Unfortunately you must not only adapt to the changing social media platforms but you have to keep adapting to all the various forms of networkings online. For some it’s fun, for others it’s a necessary

WordPress Email Issues

Every now and again we run into issues with WordPress where the email functionality has stopped working. This is usually the result of corrupted core files and/or plugin conflicts. Easy enough to fix: disable plugins or upload a fresh copy of the software and you’re good to go.

How To Survive A Good Google Dinging

This is a great demonstration of what can happen with unnatural linking schemes and getting hosed by using link farms. This company did some black-hat SEO and it came back to bite them. Luckily the article shows that it is possible to recover from a Google update nightmare, but

Garry Seay has a New Website

Garry is running for Sheriff in Union county Florida. We wish him the best of luck and he has a great new website to show off. His campaigners came to me after locating Livewire on Google. We met and discussed their needs. They needed something up and running