21 Nov 2009

So you just embedded a YouTube video in your Wordpress post and people are commenting on it… on YouTube – oops!

You probably don't want half your comments on YouTube and the half on your post. Thankfully, there's a plugin for that!

Genki Wordpress Plugin

The Genki YouTube Comments Wordpress plugin imports YouTube comments into your Wordpress posts. It's great for keeping the conversation on your blog. You can schedule comments to be imported at regular intervals or import them manually through the Admin interface.

For any post that you want to import YouTube comments into, you just add a Custom Field with youtubevidid as the key and the actual YouTube Video ID of your video as the value.

Making it pretty: adding a YouTube Gravatar

YouTube gravatarBy default, the imported comments use the default Gravatar. If you want to use a custom gravatar, instead, hack the code to change the email address used for imported posts to youtube@aralbalkan.com:

$comment_author_email = 'youtube@aralbalkan.com';

I registered this Gravatar account and mocked up a quick YouTube icon for it. Feel free to use it.

By the way, I also removed the default (and butt-ugly) " [..YouTube..] " prefix that the plugin adds to comments:

$comment_content = addslashes($ytvideo->CONTENT[0]->_text);

You can see the plugin at work on my Star Trek: The Movie on USB Stick post.

Enjoy!

Add Your Comment

Spam Protection by WP-SpamFree

Importing YouTube comments into your Wordpress blog

The Genki YouTube Comments Wordpress plugin imports YouTube comments into your Wordpress posts. It's great for keeping the conversation on your blog.

  1. Nice, I like this icon better! I just started using the Genki YouTube comments plugin and I’m psyched but for some reason it stopped working, argh! Here’s the build: http://www.theresident.net/www.new.theresident.net – have you ever encountered this problem where the plugin just stops importing comments?

    TheResident
  2. Hey Lori, I haven’t really been using it in ernest since I made this post, so I’m not really sure why it would stop working. Hope you get to the bottom of it :) (Do let us know if you do in case others have the same issue.)

    Aral
  3. Great tuto, thanks for sharing!

    Infographiste