MediaWiki:Common.js

From FragoriaWiki

(Difference between revisions)
Jump to: navigation, search
(Created page with '- Any JavaScript here will be loaded for all users on every page load.: var xhrSummaries, xhrReasons; /* Импорт дополнительных скриптов. Взят…')
(Replaced content with '- Any JavaScript here will be loaded for all users on every page load.: ')
Line 1: Line 1:
/* Any JavaScript here will be loaded for all users on every page load. */
/* Any JavaScript here will be loaded for all users on every page load. */
-
var xhrSummaries, xhrReasons;
 
-
 
-
/* Импорт дополнительных скриптов. Взято с изменениями из рувики*/
 
-
function importScript(page) {
 
-
    var url = wgScriptPath + '/index.php?title='
 
-
                            + encodeURIComponent(page.replace(' ','_'))
 
-
                            + '&action=raw&ctype=text/javascript&dontcountme=s';
 
-
    var s = document.createElement('script');
 
-
    s.src = url;
 
-
    s.type='text/javascript';
 
-
    document.getElementsByTagName('head')[0].appendChild(s);
 
-
}
 
-
 
-
importScript("MediaWiki:Dynavbar.js");
 
-
 
-
function onPageInit()
 
-
{
 
-
    createNavigationBarToggleButton(); /* [[MediaWiki:Dynavbar.js]] */
 
-
 
-
    if(typeof onPageLoad != "undefined")
 
-
    {
 
-
        onPageLoad();
 
-
    }
 
-
}
 
-
 
-
addOnloadHook(onPageInit);
 

Revision as of 12:50, 10 January 2012

/* Any JavaScript here will be loaded for all users on every page load. */
Personal tools