MediaWiki >
A stillborn project for monetizing MediaWiki.
JavaScript hack ∞
(untested, source not recorded)
Can't you also just hack mediawiki slightly to have the javascript
displayed on all pages?
I've done that for my bonsaiwiki.de
Edit /templates/xhtml_slim.pt
like this patch:
You can use CSS to hide it either by default or per user:
#p-advertisement { display:none; }
*** xhtml_slim.pt.~10~ 2004-08-02 09:59:30.000000000 +0200
--- xhtml_slim.pt 2004-08-13 13:20:18.000000000 +0200
***************
*** 130,135 ****
--- 130,153 ----
</ul>
</div>
</div>
+ <div id="p-advertisement" class="portlet">
+ <h5>Advertisement</h5>
+ <div class="pBody">
+ <script type="text/javascript"><!--
+ google_ad_client = "pub-4568250687956376";
+ google_ad_width = 120;
+ google_ad_height = 240;
+ google_ad_format = "120x240_as";
+ google_ad_channel ="6400898876";
+ google_ad_type = "text_image";
+ //--></script>
+ <script type="text/javascript"
+ src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
+ </script>
+ </div>
+ </div>
</div><!-- end of the left (by default at least) column -->
<div class="visualClear"></div>
<div id="footer">
Last updated 2019-10-27 at 09:40:15