var toLoad = "purg led ns0 lks tabs chat nav stru unw allp tbar avan cwtch popup nms cmd qed wed since goo rch edt ver vfol";
//Monobook Modulare ver.4.2.6.
//Lancia il vero monobook
// Vedi [[Wikipedia:Monobook.js/MonobookCompleto.js]]
//
document.writeln('<script type="text/javascript" src="/w/index.php?title=Wikipedia:Monobook.js/MonobookCompleto.js&action=raw&ctype=text/javascript&dontcountme=s"></script>');
//************SET STATUS***********
// adds tab "set status"
addOnloadHook(function ()
{
var tabs = document.getElementById('p-cactions').getElementsByTagName('ul')[0];
addlilink(tabs,'javascript:setCurrentStatus()','set status', 'pb-sstatus');
})
function setCurrentStatus()
{
Greeter = " Hai chiesto di cambiare il tuo logon status\n. " +
" Scegli il nuovo stato dalla lista ";
var div = document.createElement('div');
div.id = 'inlinePopupDiv';
div.style.position = 'absolute';
div.style.zIndex = 1000;
div.style.left = '5px';
div.style.top = '5px';
div.style.backgroundColor = '#FFFFFF';
div.style.borderStyle = 'solid';
div.style.borderWidth = ' medium';
div.style.borderColor = '#000000';
var top = document.createElement('div');
top.id = 'inlinePopupTop';
top.style.textAlign = 'right';
top.style.margin = '8px';
top.style.backgroundColor = '#DDDDDD';
var a = document.createElement('a');
a.appendChild( document.createTextNode('Close'));
a.href = "javascript:void RemoveNode('inlinePopupDiv')";
a.style.margin = '8px';
top.appendChild(a);
div.appendChild(top);
var greet = document.createElement('p');
greet.innerHTML = Greeter;
div.appendChild(greet);
var form = document.createElement('form');
form.name = "popupForm";
var p = document.createElement('p');
p.appendChild(document.createTextNode('Stato:'));
var sel = document.createElement('select');
sel.name = 'popupSelect';
sel.size = 1;
var option;
option = new Option("in",' ');
option.value = "in";
sel.options[sel.options.length] = option;
option = new Option("busy",' ');
option.value = "busy";
sel.options[sel.options.length] = option;
option = new Option("away",' ');
option.value = "away";
sel.options[sel.options.length] = option;
option = new Option("studying",' ');
option.value = "studying";
sel.options[sel.options.length] = option;
p.appendChild(sel);
var button = document.createElement('input');
button.value = 'OK';
button.type = 'button';
button.setAttribute('onclick', 'saveNewStatus()');
p.appendChild(button);
form.appendChild(p);
div.appendChild(form);
document.body.appendChild(div);
div.getElementsByTagName('input')[0].focus();
}
function saveNewStatus()
{
var newStatus = document.getElementById('inlinePopupDiv').getElementsByTagName('select')[0].value;
var newString='{{Utente:Wiso/StatusTemplate|'+newStatus+'|User=Wiso}}\n';
setpagecontent('Utente:Wiso/Status',newString,'stato modificato in "' + newStatus + '"');
}
|