
    function showhide_textonly(sec)
	{
	    // ricava l'id della sezione
	    var sectionid = document.getElementById(sec);

	    if (sectionid.style.display == '')
		// se la sezione e' gia' espansa
	        {
		    // nascondi la sezione...
		    sectionid.style.display='none';
	        }
	    else
		//altrimenti
	        {
		    // nascondi la sezione...
		    sectionid.style.display='';
	        }
	}

    function showonly(sec)
	{
	    var sectionid = document.getElementById(sec);
	    sectionid.style.display='';
	}

    function hideonly(sec)
	{
	    var sectionid = document.getElementById(sec);
	    sectionid.style.display='none';
	}

    function calcolaForzaPw()
	{
	    var pw = document.getElementById('newPasw0').value;

	    var pwlength = (pw.length);
	    if (pwlength > 5)
	        pwlength = 5;

	    var numnumeric = pw.replace (/[0-9]/g, "");
	    var numeric = (pw.length - numnumeric.length);
	    if (numeric > 3)
	        numeric = 3;

	    var symbols = pw.replace (/\W/g, "");
	    var numsymbols = (pw.length - symbols.length);
	    if (numsymbols > 3)
	        numsymbols = 3;

	    var numupper = pw.replace (/[A-Z]/g, "");
	    var upper = (pw.length - numupper.length);
	    if (upper > 3)
	        upper = 3;

	    var pwstrength = ((pwlength * 10) - 20) + (numeric * 10) + (numsymbols * 15) + (upper * 10);

	    if (pwstrength < 0)
	        pwstrength = 0;

	    if (pwstrength > 100)
	        pwstrength = 100;

	    return pwstrength;
	}

    function popup(img,lvl,dida)
	{
	    z=window.open(lvl + "_lib/_popUpImg.php?img="+img+"&dida="+dida,"zoom","scrollbar=no");
	    z.focus();
	}

