Показать пароль
Код:
<div id="html-footer" class="section">
<div class="container"><!-- Кнопка "Показать пароль" в форме входа © Alex_63 -->
<style>#login label[for=fld16]{margin-left:3px!important;}.pw-wrp{margin:2px 0;}
#Login_Punbb .inputfield:last-child{margin-top:17px!important;}</style>
<script>if($('#pun-login,#Login_Punbb').length)(function(){
var Sp='<span style="display:block" class="pw-wrp"><input type=checkbox id=fld16 style="margin:1px 0 0 0;float:left;"/>\
<label for=fld16 style="font-weight:400">Показать пароль</label></span>';
$('input[name="req_password"]').after(Sp);
$('#fld16,label[for="fld16"]').click(function(){
if($('#fld16').attr('checked')){$('input[name="req_password"]')[0].type='text';}
else{$('input[name="req_password"]')[0].type='password';}
});}())
</script>Код:
<!-- В смене Пароля - "Показать пароль"-->
<script>if($('#change_pass').length)(function(){
var Sp='<label style="font-weight:400"><input type=checkbox class="check" style="margin:1px 6px;"/> Показать пароль</label>';
$('#change_pass input[name^="req_new_password"]:last').after(Sp);
$('.check').click(function(){
if($(this).prop('checked')){$('#change_pass').find('input[name^="req_new_password"]').each(function(){this.type='text';});}
else{$('#change_pass').find('input[name^="req_new_password"]').each(function(){this.type='password';});}
});}())
</script></div>
</div>