
function change_input(old_input, type){
	var new_input = document.createElement("INPUT");
	new_input.type = type;
	new_input.value = old_input.value;
	new_input.name = old_input.name;
	new_input.id = old_input.id;
	if(type == 'text'){
		new_input.onfocus = function anonymous() {
			change_input(document.getElementById('password'), 'password');
		}
	}
	else{
		new_input.onblur = function anonymous() {
			if(new_input.value==''){
				change_input(document.getElementById('password'), 'text');
			}
		}
	}
	old_input.parentNode.replaceChild(new_input, old_input);
	new_input.focus();
	var ser2 = document.getElementById("password");
	if(type=='text') {
		if (ser2.value == '') {ser2.value='password';}
	}
	else {
		document.getElementById('password').focus();
		//  noful('password','ser2');
		if (ser2.value == 'password') {ser2.value=''}
		//ser2.value='';
	}
}


// forms 

var ser1 = document.getElementById("login")
if (ser1) {
ser1.onclick = new Function ("noful('login','ser1')")
ser1.onblur = new Function ("ful('login','ser1')")
}
	
function noful(val,elnm) {
  if (eval(elnm+'.value') == val) {
	eval(elnm+'.value= ""');
  }
}

function ful(val,elnm) {
if (eval(elnm+'.value') == '') {eval(elnm+'.value= val')}
}

var ser2 = document.getElementById("password")
if (ser2) {
ser2.onclick = new Function ("noful('password','ser2')")
ser2.onblur = new Function ("ful('password','ser2')")
}
	




