Hi Tilted Cerebellum,
I've seen that you've managed to manually place a Google AdSense ad into the footer of a MW page by using this code:
$wgHooks['SkinAfterContent'][] = function(&$data, $skin) { $data = '<div class="gas-bottom">'; $data .= '<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>'; $data .= '<ins class="adsbygoogle gas-bottom-first" style="display:table; width:728px; height:90px; margin:1em auto; clear:both;" data-ad-client="ca-pub-XXXXXXXXXXXXXXXX" data-ad-slot="XXXXXXXXXX"></ins>'; $data .= '<script> (adsbygoogle = window.adsbygoogle || []).push({}); </script>'; $data .= '</div>'; return true; }; ## -- Adsense footer end -- ##
It works fine, thanks for that! Could you edit the code so I can use it in the sidebar also? I'm sitting for hours and am not able to manage this :-/ Thanks a lot!!!