מייבאים כמותיים, בדוקי עריכות אוטומטית, ביוראקראטן, אינטערפעיס רעדאקטארן, emailconfirmed, אינטערפעיס אדמיניסטראַטאָרן, מנטרים, סיסאפן, צוות טכני, מייבאים, מעדכנים, אספקלריה רעדאקטארן
102,362
רעדאגירונגען
אין תקציר עריכה |
אין תקציר עריכה |
||
| (11 מיטלסטע ווערסיעס פון 2 באַניצער נישט געוויזן.) | |||
| שורה 1: | שורה 1: | ||
// | // ערמעגליכט צו אויספירן א זוך דורכ'ן באניצן פארקירצטע געביט נעמען אנגעשטעלט פון פריער. די ליסטע קען מען טרעפן [[מעדיעװיקי שמועס:Gadget-ShortNSSearch|דא]] | ||
// | // געשריבן דורך [[w:he:user:Yonidebest]] | ||
// | // | ||
function checkSearchInput() { | function checkSearchInput() { | ||
var shortcuts = new Array(21) | |||
for (var i = 0; i < shortcuts.length; i++) | |||
shortcuts[i] = new Array(2); | |||
shortcuts[0][0] = 'ש:'; | |||
shortcuts[0][1] = 'שמועס:'; | |||
shortcuts[1][0] = 'מ:'; | |||
shortcuts[1][1] = 'המכלול:'; | |||
shortcuts[2][0] = 'מש:'; | |||
shortcuts[2][1] = 'המכלול שמועס:'; | |||
shortcuts[3][0] = 'ק:'; | |||
shortcuts[3][1] = 'קאַטעגאָריע:'; | |||
shortcuts[4][0] = 'קש:'; | |||
shortcuts[4][1] = 'קאַטעגאָריע שמועס:'; | |||
shortcuts[5][0] = 'ה:'; | |||
shortcuts[5][1] = 'הילף:'; | |||
shortcuts[6][0] = 'הש:'; | |||
shortcuts[6][1] = 'הילף שמועס:'; | |||
shortcuts[7][0] = 'ב:'; | |||
shortcuts[7][1] = 'באַניצער:'; | |||
shortcuts[8][0] = 'בש:'; | |||
shortcuts[8][1] = 'באַניצער שמועס:'; | |||
shortcuts[9][0] = 'פ:'; | |||
shortcuts[9][1] = 'פארטל:'; | |||
shortcuts[10][0] = 'פש:'; | |||
shortcuts[10][1] = 'פארטל שמועס:'; | |||
shortcuts[11][0] = 'מוו:'; | |||
shortcuts[11][1] = 'מעדיעװיקי:'; | |||
shortcuts[12][0] = 'מווש:'; | |||
shortcuts[12][1] = 'מעדיעװיקי שמועס:'; | |||
shortcuts[13][0] = 'ט:'; | |||
shortcuts[13][1] = 'טעקע:'; | |||
shortcuts[14][0] = 'טש:'; | |||
shortcuts[14][1] = 'טעקע שמועס:'; | |||
shortcuts[15][0] = 'מו:'; | |||
shortcuts[15][1] = 'מוסטער:'; | |||
shortcuts[16][0] = 'מוש:'; | |||
shortcuts[16][1] = 'מוסטער שמועס:'; | |||
shortcuts[17][0] = 'בב:'; | |||
shortcuts[17][1] = 'באַזונדער:בײַשטײַערונגען/'; | |||
shortcuts[18][0] = 'ס:'; | |||
shortcuts[18][1] = 'באַזונדער:'; | |||
shortcuts[19][0] = 'ר:'; | |||
shortcuts[19][1] = 'רוי:'; | |||
shortcuts[20][0] = 'ד:'; | |||
shortcuts[20][1] = 'דרעפט:'; | |||
text = document.getElementById('searchInput'); | |||
for (i = 0; i < shortcuts.length; i++) { | |||
var rxEdit = new RegExp('^ר' + shortcuts[i][0]); | |||
if (rxEdit.test(text.value)) { | |||
text.value = text.value.replace(rxEdit, shortcuts[i][1]); | |||
document.location = '//yi.hamichlol.org.il/w/index.php?title=' + text.value + '&action=edit'; | |||
return false; | |||
} | |||
var rxHistory = new RegExp('^ה' + shortcuts[i][0]); | |||
if (rxHistory.test(text.value)) { | |||
text.value = text.value.replace(rxHistory, shortcuts[i][1]); | |||
document.location = '//yi.hamichlol.org.il/w/index.php?title=' + text.value + '&action=history'; | |||
return false; | |||
} | |||
var rxPI = new RegExp('^/'); | |||
if (rxPI.test(text.value)) { | |||
document.location = '//yi.hamichlol.org.il/w/index.php?title=' + "באַזונדער:הדף_שלי" + text.value; | |||
return false; | |||
} | |||
} | } | ||
var | for (i = 0; i < shortcuts.length; i++) { | ||
var rx = new RegExp('^' + shortcuts[i][0]); | |||
text.value = text.value.replace(rx, shortcuts[i][1]); | |||
} | } | ||
return true; | |||
} | } | ||
function addCheckSearchInput() { | function addCheckSearchInput() { | ||
var form = document.getElementById('searchform'); | |||
if (!form) { | |||
return; | |||
} | |||
form.onsubmit = function () { return checkSearchInput(); } | |||
} | } | ||
$(addCheckSearchInput); | $(addCheckSearchInput); | ||
רעדאגירונגען