September 6th, 2006

Managing Multiple Chitika eMinimalls Ads in WordPress

I’d wager that a substantial percentage of product bloggers have learnt the power of Chitika eMinimalls (aff link) over the past year or so - perhaps even to the extent that their eMinimalls revenue exceeds AdSense on some of their product blogs.

So, it shouldn’t be surprising to find bloggers who want to place multiple Chitika ads on the same page - all of which targeted via the same keywords to maximize context. But if you use the default approach of the various Chitika plugins available for WordPress (i.e. in-post tags like [eminimall]), you will have to enter keywords manually for each ad you place within the post (unlike for contextual ads like AdSense which do not suffer from this problem).

Let’s assume you want to place an ad above and below your content, like this:
eMinimalls-layout

For Chitika’s official plugin, you’d have to put [eminimall width="468" height="60" products="dvd, video"] at the top, and [eminimall width="468" height="180" products="dvd, video"] at the bottom of your content via your Write Post panel. Not only is this a waste of time, this implementation is inflexible. If you want to change the position of your ads, you’d have to edit each of your posts manually. Clearly, using the plugin (or any other Chitika plugin) is only useful if you want to place an ad in a non-fixed or random location somewhere within the content of your post.

Therefore, instead of using plugins, why not leverage the power of WordPress’ core itself? Here are two possible approaches:

  • Using Post Titles
    One method of automating the process is to instruct WordPress to put your post titles as your eMinimalls ad keywords. This approach is optimal if your post titles mostly contain only your product name, e.g. “60GB iPod Video Unveiled”.
    1. Edit your Single Post template via Presentation >> Theme Editor.
    2. Where you want to place your ads, paste the appropriate ad code from your Chitika admin panel. Based on the sample layout above, for Ad 1:

      <script type="text/javascript"><!--
      ch_client = "YOURID";
      ch_width = 468;
      ch_height = 60;
      ch_color_border = "#FFFFFF";
      ch_color_bg = "#FFFFFF";
      ch_color_title = "048DDC";
      ch_color_text = "#000000";
      ch_non_contextual = 1;
      ch_nosearch = 1 ;
      ch_sid = "Ad 1";
      var ch_queries = new Array( "<?php the_title(); ?>” );
      var ch_selected=Math.floor((Math.random()*ch_queries.length));
      ch_query = ch_queries[ch_selected];
      //–></script>
      <script  src=”http://scripts.chitika.net/eminimalls/mm.js” type=”text/javascript”>
      </script>

      And for Ad 2:

      <script type="text/javascript"><!--
      ch_client = "YOURID";
      ch_width = 468;
      ch_height = 180;
      ch_color_border = "#FFFFFF";
      ch_color_bg = "#FFFFFF";
      ch_color_title = "048DDC";
      ch_color_text = "#000000";
      ch_non_contextual = 1;
      ch_nosearch = 1 ;
      ch_sid = "Ad 2";
      var ch_queries = new Array( "<?php the_title(); ?>” );
      var ch_selected=Math.floor((Math.random()*ch_queries.length));
      ch_query = ch_queries[ch_selected];
      //–></script>
      <script  src=”http://scripts.chitika.net/eminimalls/mm.js” type=”text/javascript”>
      </script>

    3. The only difference between your normal ad code and the ones above is the bolded portion, i.e. <?php the_title(); ?>. It’s a WP template tag to display your post title.
  • Using Custom Fields
    If the above approach doesn’t work for you (perhaps due to too many unrelated words in your post title), you might want to use WP’s custom fields instead. This way, you can manually define the keywords you want to use in each post, but do it only once for however many Chitika ads you want to display for those keywords.
    1. In each of your posts, you will want to create a custom field for your keywords, something like product_keywords perhaps.
    2. Then, repeat all the steps in approach above. But instead of putting <?php the_title(); ?> in your eMinimalls code, put this instead:

      <?php get_post_meta($post->ID, 'product_keywords', TRUE); ?>

    3. What that template tag does is to pull the keywords you entered in the product_keywords custom field, and dump them in your eMinimalls code. For more information on get_post_meta(), read the WP Codex article on Using Custom Fields.

Either one of these approaches provide you a simple and flexible framework to manage your Chitika ads. Admittedly, the custom fields approach highlighted above will be extremely tedious to implement if you already have hundreds of posts, but you won’t regret using it - especially when you start experimenting with different ad positions in the future (all you’ll have to do is to move one instance of code around via your Theme Editor).

P.S.: Another advantage of using custom fields (or any other free tagging approach really, e.g. Ultimate Tag Warrior) is that you end up with a set of keywords you can use for many other things.

If you found this post useful, keep updated with future posts by subscribing to blogHelper (for free) through RSS or email.

Remember to share this post as well (if you liked it, of course): These icons link to social bookmarking sites where readers can share and discover new web pages.
  • del.icio.us
  • digg
  • Fark
  • Furl
  • Ma.gnolia
  • NewsVine
  • Reddit
  • YahooMyWeb

4 Comments

  • 1

    […] Managing Multiple Chitika eMinimalls Ads in WordPress | blogHelper var ch_queries = new Array( “< ?php the_title(); ?>” ); or < ?php get_post_meta($post->ID, ‘product_keywords’, TRUE); ?> to grab all the keywords - pretty slick (tags: Chitika WordPress) […]

  • 2

    Thanks for the article.

    I have found inserting chitika ads of two different sizes in the same post (using wordpress 2+) gives problems - only multiple copies of the same default size seem to work. Keywords can be changed without problems. Any others with similar problems?

    I’ve found that putting chitika ads next to an large image of the product boosts clicks 2-3 fold.

  • 3

    However I occasionally find a website that is only in French and I want to know what it says.

    http://www.degisimbilgisayar.com.tr

  • 4

    However I occasionally find a website that is only in French and I want to know what it says.

Leave a Reply