Utente:Kal-El/monobook.js: differenze tra le versioni
Contenuto cancellato Contenuto aggiunto
m rb manuale |
m riproviamo... |
||
Riga 42:
addNavBarLinks(); // add navigation bar links
talkpageplus(); // make red talk page links start new sections
addEditSection0(); // aggiunge pulsante "0"
// remove the logout access key
ta['pt-logout'] = new Array(null, null);
Riga 170 ⟶ 171:
div.getElementsByTagName('input')[0].focus();
}
/**** Edita la sezione 0 ****/
function addEditSection0()
{
ta['ca-edit-0'] = ['', 'Modifica la sezione 0'];
if(!document.getElementById) return;
var x = document.getElementById('ca-edit');
if(!x) return;
var y = document.createElement('LI');
y.id = 'ca-edit-0';
if(x.className == 'selected'){
if(/&action=edit§ion=0$/.test(window.___location.href)){
x.className = 'istalk';
y.className = 'selected';
} else {
x.className = 'selected istalk';
}
} else if(x.className == 'selected istalk'){
if(/&action=edit§ion=0$/.test(window.___location.href)){
x.className = 'istalk';
y.className = 'selected istalk';
} else {
y.className = 'istalk';
}
} else {
y.className = x.className;
x.className = 'istalk';
▲ }
var z = document.createElement('A');
if(x.children){
z.href = x.children[0].href + '§ion=0';
z.appendChild(document.createTextNode('0'));
y.appendChild(z);
document.getElementById('p-cactions').children[1].insertBefore(y,x.nextSibling);
}else{
z.href = x.childNodes[0].href + '§ion=0';
z.appendChild(document.createTextNode('0'));
y.appendChild(z);
document.getElementById('p-cactions').childNodes[3].insertBefore(y,x.nextSibling);
}
}
/**** Make the top links look better ****/
|