What I did:
$wgHooks['SkinBuildSidebar'][] = function($skin, &$bar) { $out = <<< EOT <iframe src="//rcm-na.amazon-adsystem.com/e/cm?o=1&p=29&l=ur1&category=software&banner=0FNP2ZP63JZJBWQRD082&f=ifr&linkID=ea3dcccece96f5ba66814f531937489c&t=example-20&tracking_id=example-20" width="120" height="600" scrolling="no" border="0" marginwidth="0" style="border:none;" frameborder="0"></iframe> EOT; $out .= "<script>$('#p-Ads').addClass('persistent');</script>"; $bar['Ads'] = $out; return true; };
The intended ads isn't showing.
even the following example has no effect on the wiki in question:
$wgHooks['SkinBuildSidebar'][] = function( $skin, &$bar ) { $bar['navigation'][] = [ 'text' => $skin->msg( 'wikimediashoplink-linktext' ), 'href' => '//shop.wikimedia.org', 'title' => $skin->msg( 'wikimediashoplink-link-tooltip' ), 'id' => 'n-shoplink', ]; };
Please advise.