Jerome’s Keywords and WordPress 2.0

I was having some problems with my keywords getting deleted when updating a post (using Jerome’s Keywords 1.8). The problem was a result of a blank textarea on the page to edit a post. Wasn’t hard to fix at all.

The textarea, with a header of “Keywords”, shows up blank when editing a post. The initial post is good because that text area is filled out manually. jeromes-keywords.php was using “$postdata->ID” as a reference in the get_post_meta() function. $postdata->ID didn’t contain any value at all.

After doing a little digging, I found I could get a posts ID using $post->ID, notice the missing “data”. It only takes a few steps to get Jerome’s Keywords working 100% in WordPress 2.0.
1. Open wp-content/plugins/jeromes-keywords.php in a text editor.
2. On line 553, change the line that says “global $postdata, $content” to read “global $post, $content”.
3. On line 555, change “get_post_meta($postdata->ID, KEYWORDS_META, true)” to “get_post_meta($post->ID, KEYWORDS_META, true)”.
4. Save jeromes-keywords.php, you’re done.

After doing that, the keywords textarea created by the plugin will be populated with your original keywords. I guess that textarea must have the keywords there all the time, even when editing. Before, my keywords weren’t in the “keywords” textarea, they were only in a custom field.

It appears that Jerome’s Keywords deletes post meta every time that post is edited. And I think that’s the desired functionality for some reason. I only say that after looking at the code for a half hour or so. I think the post would end up with one custom field named “keywords” for every time the post is edited or updated. So, update a post 4 times and you’ll have 4 identical custom fields named “keywords”.

All of my favorite plugins are now working very well for me with WordPress 2.0-RC1.


More WordPress and some FireFox

UPDATE: Get SK2-WP2Compatibility, a plugin for Spam Karma 2. It fixes the comment count problem mentioned below when using Spam Karma 2 with WordPress 2.0. OK, just wanted to get that out in the open. Please continue.

Now that I’ve spent a little more time with WordPress 2.0 RC1, I’ve discovered a plugin compatibility problem that’s probably going to destroy me. Spam Karma 2 causes some problems when updating the “comment_count” value in the “wp_posts” table. It doesn’t just cause problems displaying comment numbers, I had to manually updated that field for some posts. But, it’s not like this type of thing wasn’t expected. I’m not brave enough to run slackware-current on my main workstation anymore, this works for me though.

So, I can either use Spam Karma and not have any comment counts for new or updated posts, or I can just stop using Spam Karma. I really don’t want to let Spam Karma go. I’ve already seen about 200 trackback/comment spams since disabling Spam Karma earlier today. I really hope to see a new release of Spam Karma that works with WordPress 2.0. I guess this problem was known about a few weeks ago. I somehow didn’t notice it when I upgraded to 2.0 beta 1 and then to 2.0 beta 2.

Anybody know of a comment/trackback spam WordPress plugin that’s known to work with 2.0? There’s the list in the support forums, which also happens to discuss the Spam Karma problems. I may see if the latest WordPress Hashcash will work at all.

There is good news though, not really relating to WordPress though. FireFox 1.5 stable is out! You can get FireFox 1.5 at the new official home of FireFox and Thunderbird,

Also, my favorite Mint Pepper has been updated to work with Mint 1.23. I was thinking of downgrading to Mint 1.14 just so I could have the Outclicks Pepper. Andrew Sutherland couldn’t have picked a better time to release his updated pepper.

CONTINUED UPDATE: Too bad I didn’t see this about an hour ago. Looks like I’ll get to keep my Spam Karma thanks to SK2-WP2Compatibility, a plugin for Spam Karma 2.

SK2-WP2Compatibility is a plugin for Spam Karma 2. It has no effect without Spam Karma 2.0 or higher being already installed on your WordPress system.
This plugin has no spam fighting or spam killing abilities. Instead, it is intended to provide a way by which all users moving to WordPress 2.0 can enjoy the benefits of Spam Karma – without having to worry about WordPress 2.0 specific changes.

Might not need that SK2 plugin for too long, there’s word of a Spam Karma 2.1 soon.