MediaWiki:Common.js: Difference between revisions

No edit summary
No edit summary
Tag: Manual revert
 
(5 intermediate revisions by the same user not shown)
Line 47: Line 47:
mw.loader.using('jquery', function () {
mw.loader.using('jquery', function () {
     $(function () {
     $(function () {
        // Only add if it doesn't exist
         if (!$('#promo-banner').length) {
         if (!$('#promo-banner').length) {
             var promo = $('<div id="promo-banner">🚀 Need SEO Services? <a href="/wiki/SEO_Services" target="_blank">Click here to learn more</a></div>');
            var promoContainer = $('<div id="promo-banner-container"></div>');
              
             var promo = $('<div id="promo-banner">Want to rank your website at the top of Google? Or need expert SEO services to boost your business? <br>🚀 <a href="https://www.upwork.com/freelancers/eliteseoexpert" target="_blank">Hire me on Upwork</a> now and let’s grow your traffic!</div>');
             // Place the banner right under the header search bar
             promoContainer.append(promo);
             $('#siteSub').before(promo);
 
             // Add it right under the header in Vector 2022
             var headerArea = $('.vector-header-container');
            if (headerArea.length) {
                headerArea.after(promoContainer);
            }
         }
         }
     });
     });
});
});