Extension:KeepSearches

What can this extension do?
KeepSearches Extension keeps into the mediawiki database, counts the times, and get the last date-time, all the query searches made by users in your mediawiki. This extension comes with a "most searched terms tag cloud" render function, see instructions below to print the tag cloud on your mediawiki skin.

Important: This extension does not keeps private info in any way, KeepSearches extension just its useful for anonymous statistical purposes.

Usage
Just install it

Installation

 * 1) Download the files from SVN and place them in $IP/extensions/KeepSearches/
 * 2) Add the following to LocalSettings.php:

Database table creation
Open a console, go to the KeepSearches extension directory and run this command:

If everything goes fine, you will see this message: You must run this script to create the keep_searches table, and this is mandatory to use this extension properly.

How to print the "most searched terms tag cloud"
This extension comes with a "most searched terms tag cloud" render function

Just use it into your skin (YourSkinName.php file) like this (it`s an example, you can change the numbers):



or without php start and end tags if you want to include the cloud into php itself

generateTagCloudSearches ( 40, 0 );

Where the first param is $SIZE_LIST, the number of the items in the list (top 10, or top 20, etc...) and ths second param is $SIZE_OFFSET, the number where start to count on the list.

css sample for cloud tag
Add this classes to your css file to format your tag cloud:

.tagcloud { list-style-type:none; margin:0; width: 200px; text-align:left; }

.tagcloud li { display:inline; }

.tagcloud ul, ol { list-style-image:none; list-style-position:outside; list-style-type:none; margin:0; padding:0; }

.tagcloud a { color: #999; font-weight: bold; padding-right:2px; }

Please don't hesitate to contact me : daniel [at] mp2p.net