Files
2026-04-24 15:32:21 +02:00

35 lines
1.6 KiB
Smarty

<div class="header">Zmiana has³a</div>
<br />
<form action="{url value=user,changePassword}" method="post">
<table class="adminTable" cellpadding="2" cellspacing="2" style="width:50%;" align="center">
<tr>
<td>Stare has³o: </td>
<td>
<input class="input" type="password" name="oldPassword" id="oldPassword" />
</td>
</tr>
<tr>
<td>Nowe has³o: </td>
<td>
{literal}
<input class="input" type="password" id="pass1" name="newPassword" onkeyup="this.style.backgroundImage='none'; if(this.value.length<=4){this.style.backgroundColor='#ff7e7e';}else if(this.value.length>4 && this.value.length<7){this.style.backgroundColor='#fffe8f';}else{this.style.backgroundColor='#4fff57';}" />
</td>
</tr>
<tr>
<td>Powtórz nowe has³o: </td>
<td>
<input class="input" type="password" id="pass2" name="confirmPassword" onkeyup="this.style.backgroundImage='none'; var tmpVal=$('pass1'); if(this.value==tmpVal.value){this.style.backgroundColor='#4fff57'; if(tmpVal.value.length>4){tmpVal.style.backgroundColor='#4fff57';}}else{this.style.backgroundColor='#ff7e7e';}" />
</td>
</tr>
<tr>
<td></td>
<td><input type="submit" value="Zapisz" class="button" onclick="if($('oldPassword').value!='' && $('pass1').value==$('pass2').value && $('pass1').value.length>4){return true;} else if($('oldPassword').value==''){$('oldPassword').style.backgroundImage='none'; $('oldPassword').style.backgroundColor='#ff7e7e'; return false;} else if($('oldPassword').value==''){$('oldPassword').style.backgroundImage='none'; $('oldPassword').style.backgroundColor='#ff7e7e'; return false;} else {return false;}" /></td>
</tr>
<tr>
<td></td>
{/literal}
<td>{$msg}</td>
</tr>
</table>
</form>