پرش به محتوا

مدیاویکی:Gadget-popups.js: تفاوت میان نسخه‌ها

از دانشنامه علوم انسانی
imported>Reza1615
جایگزینی صفحه با '// update able version wikipedia:User:Lupin/popups importScriptURI("//en.wikipedia.org/w/index.php?title=User:Lupin/popups.js&action=raw&ctype=text/javascript...'
imported>Yamaha5
بدون خلاصۀ ویرایش
 
(۴ نسخهٔ میانی ویرایش شده توسط ۲ کاربر نشان داده نشد)
خط ۱: خط ۱:
// update able version [[wikipedia:User:Lupin/popups]]
//محتویات User:Lupin/popups.js کپی شد تا بتوان پنجره‌ها را راست بازشو تنظیم کرد
importScriptURI("//en.wikipedia.org/w/index.php?title=User:Lupin/popups.js&action=raw&ctype=text/javascript");
//fa-translation
//fa-translation
importScriptURI('//fa.wikipedia.org/w/index.php?title=مدیاویکی:Gadget-popups.js/fa-translation.js'  
mw.loader.load('//fa.wikipedia.org/w/index.php?title=مدیاویکی:Gadget-popups.js/fa-translation.js'  
     + '&action=raw&ctype=text/javascript');
     + '&action=raw&ctype=text/javascript');
// update able version [[wikipedia:User:Lupin/popups]]
var popScript    = '//en.wikipedia.org/w/index.php?action=raw&ctype=text/javascript&title=MediaWiki:Gadget-popups.js';
var popStyleSheet = '//en.wikipedia.org/w/index.php?action=raw&ctype=text/css&title=MediaWiki:Gadget-navpop.css';
//به دلیل مشکلات گزارش شده برای اینترنت از کد کپی شده در ویکی‌فا استفاده می‌کنیم
//var popScript    = '//fa.wikipedia.org/w/index.php?action=raw&ctype=text/javascript&title=MediaWiki:Gadget-popups/localcopy.js';
//var popStyleSheet = '//fa.wikipedia.org/w/index.php?action=raw&ctype=text/css&title=MediaWiki:Gadget-navpop.css';
if ( window.localCSS ) { popStyleSheet = 'http://localhost:8080/js/navpop.css'; }
function popups_importScriptURI(url) {
var s = document.createElement('script');
s.setAttribute('src',url);
s.setAttribute('type','text/javascript');
document.getElementsByTagName('head')[0].appendChild(s);
return s;
}
function popups_importStylesheetURI(url) {
return document.createStyleSheet ? document.createStyleSheet(url) : popups_appendCSS('@import "' + url + '";');
}
function popups_appendCSS(text) {
var s = document.createElement('style');
s.type = 'text/css';
s.rel = 'stylesheet';
if (s.styleSheet) s.styleSheet.cssText = text //IE
else s.appendChild(document.createTextNode(text + '')) //Safari sometimes borks on null
document.getElementsByTagName('head')[0].appendChild(s);
return s;
}
popups_importStylesheetURI(popStyleSheet);
popups_importScriptURI(popScript);

نسخهٔ کنونی تا ۲۷ اکتبر ۲۰۱۷، ساعت ۱۹:۳۶

//محتویات User:Lupin/popups.js کپی شد تا بتوان پنجره‌ها را راست بازشو تنظیم کرد
//fa-translation
mw.loader.load('//fa.wikipedia.org/w/index.php?title=مدیاویکی:Gadget-popups.js/fa-translation.js' 
    + '&action=raw&ctype=text/javascript');

// update able version [[wikipedia:User:Lupin/popups]]
var popScript     = '//en.wikipedia.org/w/index.php?action=raw&ctype=text/javascript&title=MediaWiki:Gadget-popups.js';
var popStyleSheet = '//en.wikipedia.org/w/index.php?action=raw&ctype=text/css&title=MediaWiki:Gadget-navpop.css';
//به دلیل مشکلات گزارش شده برای اینترنت از کد کپی شده در ویکی‌فا استفاده می‌کنیم
//var popScript     = '//fa.wikipedia.org/w/index.php?action=raw&ctype=text/javascript&title=MediaWiki:Gadget-popups/localcopy.js';
//var popStyleSheet = '//fa.wikipedia.org/w/index.php?action=raw&ctype=text/css&title=MediaWiki:Gadget-navpop.css';
if ( window.localCSS ) { popStyleSheet = 'http://localhost:8080/js/navpop.css'; }

function popups_importScriptURI(url) {
	var s = document.createElement('script');
	s.setAttribute('src',url);
	s.setAttribute('type','text/javascript');
	document.getElementsByTagName('head')[0].appendChild(s);
	return s;
}

function popups_importStylesheetURI(url) {
	return document.createStyleSheet ? document.createStyleSheet(url) : popups_appendCSS('@import "' + url + '";');
}

function popups_appendCSS(text) {
	var s = document.createElement('style');
	s.type = 'text/css';
	s.rel = 'stylesheet';
	if (s.styleSheet) s.styleSheet.cssText = text //IE
	else s.appendChild(document.createTextNode(text + '')) //Safari sometimes borks on null
	document.getElementsByTagName('head')[0].appendChild(s);
	return s;
}

popups_importStylesheetURI(popStyleSheet);
popups_importScriptURI(popScript);