Extension:AdsWherever

AdsWherever is a very simple extension that displays any advertising codes on your wiki page. Nothing fancy here, it just works.

Source
Copy the following code into extensions/AdsWherever.php:

Installation

 * Create the file AdsWherever.php and paste the code shown above. Make sure there are no empty lines after the final php exit tag.
 * Upload adswherever.php to your $IP/extensions directory.
 * Add the following lines at the end of LocalSettings.php:

Usage
After you set the variable in $ad, insert a tag into anywhere of your page. Here is an example to insert the google adsense code. 