User:DStoykov/defaultsort.js: Difference between revisions

Content deleted Content added
No edit summary
m Remove legacy globals per phab:T72470 (via WP:JWB)
 
(One intermediate revision by one other user not shown)
Line 2:
 
function defaultsort() {
//var apiurl = mw.config.get('wgServer')+mw.config.get('wgScriptPath')+'/api.php?action=query&meta=siteinfo&siprop=namespaces&format=xml';
//var xmlhttp = window.XMLHttpRequest ? new XMLHttpRequest() : window.ActiveXObject ? new ActiveXObject("Microsoft.XMLHTTP") : null;
//xmlhttp.open('GET',apiurl, false);
Line 53:
}
 
addOnloadHook$(function () {
if(document.forms.editform) {
mw.util.addPortletLink('p-cactions', 'javascript:defaultsort()', 'defaultsort', 'ca-defaultsort', '', '', document.getElementById('ca-purge'));