function passwordChanged(element_id) {
	var strength = document.getElementById('strength');
	var strongRegex = new RegExp("^(?=.{8,})(?=.*[A-Z])(?=.*[a-z])(?=.*[0-9])(?=.*\\W).*$", "g");
	var mediumRegex = new RegExp("^(?=.{7,})(((?=.*[A-Z])(?=.*[a-z]))|((?=.*[A-Z])(?=.*[0-9]))|((?=.*[a-z])(?=.*[0-9]))).*$", "g");
	var enoughRegex = new RegExp("(?=.{6,}).*", "g");
	var pwd = document.getElementById(element_id);
	if (pwd.value.length==0) {
		strength.innerHTML = '';
	} else if (false == enoughRegex.test(pwd.value)) {
		strength.innerHTML = '<b>Vnos vsebuje premalo znakov!</b>';
	} else if (strongRegex.test(pwd.value)) {
		strength.innerHTML = '<font style="color:#0fa000;font-weight:bold;">Odlično!</font>&nbsp;<div style="margin:0;padding:0;width:100px;background-color:#0fa000;" align="left"><img src="http://www.toogle.si/img/blank.gif" alt="blank" width="1" height="7" /></div>';
	} else if (mediumRegex.test(pwd.value)) {
		strength.innerHTML = '<font style="color:#ffae00;font-weight:bold;">Srednje!</font>&nbsp;<div style="margin:0;padding:0;width:100px;background-color:#ffae00;" align="left"><img src="http://www.toogle.si/img/blank.gif" alt="blank" width="1" height="7" /></div>';
	} else {
		strength.innerHTML = '<font style="color:#ff0000;font-weight:bold;">Slabo!</font>&nbsp;<div style="margin:0;padding:0;width:100px;background-color:#ff0000;" align="left"><img src="http://www.toogle.si/img/blank.gif" alt="blank" width="1" height="7" /></div>';
	}
}