Search Cloud (Zeitgeist)

3rd May 2007 stk

Put Your Head in the Clouds - It's Easy!

The installation for this plug-in is easy. Just follow the steps below.

  1. Download: Grab the latest version from the plug-in repository on ...

    am_search_cloud_plugin (plug-in for b2evo v1.8.x & v1.9.x)

  2. Unzip & Upload: Unzip the file into the "/plugins" folder of your v1.8.x or v1.9.x b2evolution installation. It will make a folder called "am_search_cloud_plugin", which you need to upload to your b2evolution server, putting it into the same "/plugins" location.

  3. Install the Plugin: In the back-office, head to the "App Setting" -> "Plugins" tab. In the "Available Plugins" list, you should see "AM Search Cloud". Click [Install] in the "Actions" list, on the right. BOOM! It's installed.

  4. Add the Skin Tag: Next, you tell your skin where you want the cloud to show up. To do this, edit your skin's _main.php file and add the following PHP code. (If you're not sure where to put it, a good starting point is right before your "bPosts" DIV. If you're putting inside of existing PHP tags, you don't need the PHP tags included here.)


    <?php $Plugins->call_by_code'am_srchcloud'array(
              // parameters go here
              ) ); 

BOOM! You're done. How simple was that?


Tweaking the Code

Settings (Back-Office)

There are some settings you might want to modify or play with, in the back-office. Head to the installed plug-in and click the little 'paper & pencil' icon in the "actions" column (far right). This allows you to edit the plug-in settings. Those settings are described below.

  1. Cache Lifetime: Length of time (in minutes) that the search terms in the cloud will be cached for. This saves server resources for high-traffic blogs. Defaulted Value: 60
  2. Max Length: Maximum number of characters for a particular search string. This provides a mechanism to truncate very long search strings and keep them from 'breaking out' of their containing block elements. Defaulted Value: 0 (displays the full string)
  3. Filter Words: This is a comma-separated list of objectionable words you may wish to filter out of search strings. This provides a means to keep profanity and other such words out of the search cloud. Defaulted Value: No Filtering
  4. Filter Character: If 'Filter Words' is enabled, this is the character that is used to replace the characters contained in the filtered word. Defaulted Value: * (e.g., 'cuss word' becomes '**** ****')


Parameters (Skin Tag)

There are a bunch of parameters (all defaulted if you utilize the skin tag in the code above) which control a variety of things. Rather than discuss each one, we've put a complete skin tag below, with all of the parameters defaulted. (You can copy/paste THIS code into your skin's _main.php file, in place of the one above, and modify values as you see fit).


<?php $Plugins->call_by_code'am_srchcloud'array(
        'blog'=>'',             // blog_ID for search terms ('' = <em>current</em> blog)
        'limit'=>40,          // number of search terms to show
        'title'=>'<h3>Search Cloud</h3>'// cloud title
        'order'=>'rand',        // order of the terms (asc/desc/rand)
        'show_once'=>true,    // show cloud once inside blog loop
        'before_all'=>'<div id="search_cloud">'// output before the cloud
        'after_all'=>'</div>',  // output after the cloud
        'block_start'=>'<ul>',  // start of the cloud list
        'block_end'=>'</ul>',   // end of the cloud list
        'before_each'=>'<li>',  // start of each cloud term
        'after_each'=>'</li>',  // after each cloud term
        'hover_title'=>'Searched #count# times - Read it!'// link bubble-text                  
          ) ); 


  1. Introduction
  2. Installation (v1.8.x & v1.9x)
  3. Styling the Cloud
  4. The Future


Comment from: EdB
Nice. One problem not specific to this plugin though: when I changed it to P tags with nothing preceding and a space following it decided since I had nothing preceding it would use it's default value of LI. Had to make my changes to the actual plugin therefore.
05/04/07 @ 20:15
Hi EdB,
What do you expect if you use a plugin coded by a blonde? Sheesh :P

I've corrected this problem, but I've got one or two other little fixes to do as well and then we'll release a 1.1.1 ... damn, we're starting to sound all evcore with our version numbers already :S

05/05/07 @ 09:41
Comment from: Farhad
It has problem with UTF-8.....................
08/20/07 @ 17:38

works great. The only thing not working for me is th eparameter for the sort order. Regardless if I am using "asc" or "desc" it is always displayed randomly... Any idea?

03/22/08 @ 13:48
From the looks of your sidebar you've solved this ?

03/23/08 @ 17:57
What about b2evo v2.x ?
04/04/08 @ 21:49
The chances are that it works in 2.x as well

04/16/08 @ 09:26
Comment from: slamp
Is there any way to display the search tag cloud on a backoffice page ?
05/16/08 @ 12:31
Hi Slamp,

Yes there is, but I'd need to add a fair amount of code. It's not hard but make take me a while

05/17/08 @ 13:06

Comments are closed for this post.