Archive for the ‘plugin’ Category

Meta Keyword Generator

Thursday, April 5th, 2007

Ever found your self sitting and trying to decide which meta keywords to put on your site. waste no more time on it! let the meta keyword generator do the boring job for you! Max was messing around with a plugin created by ludovic at http://lbcd78.fr that generated keywords based on the current pages title and content. I like the idea, it is easy to understand, quick to install and works like a charm. except his plugin was in his native tongue, french. Max had found an exclusion word list on the net, words that should be ignored, but it did still create alot of errors.

After looking through the code I decided to start from scratch using the old script as a base to work on and after a few hours I came up with this little nifty script.

  1. Copy the sourcecode into a new file called mkg.php
  2. Activate the plugin, go to Options > Meta Keyword Generator and tweak it to fit your requirements
  3. Insert the following line of code in your templates header file, proberly called header.php

<meta name="keywords" content="<?php mkg(); ?>" />

I have created a highlighted version of the source instead of updating and maintaining a zip archive. It can now be found right here