February 24, 2008

wp-o-matic quick & dirty duplicate post fix

Posted in Open Source, wordpress tagged , , , , , , at 12:23 am by ilanco

I’m getting a lot of duplicate posts using wp-o-matic and if you are reading this, you probably have the same problem.

Instead of fixing wp-o-matic (that’s the developer’s job) I just changed my local wordpress to ignore posts with the same title.

Here is how it works :

  1. Open up wp-includes/post.php in your favorite editor
  2. at approx line 703 you will find the following line :
    if ($post_name_check || in_array($post_name, $wp_rewrite->feeds) ) {
  3. After this insert a new line of code :
    return 0;
  4. save (you did make a backup, right?).
  5. All done.