<script language=javascript>
//getting original ids
var idUser = "";
var idPass = "";
//generating mask ids
var d = new Date();
var mask = "_" + d.getFullYear() + (d.getMonth() + 1) + d.getDate() + "_" + d.getHours()
+ d.getMinutes() + d.getSeconds();
$(document).ready(function(){
//getting original ids
idUser = $('#txtUser')[0].id;
idPass = $('#txtPassword')[0].id;
//Adding Mask to Ids
$('#txtUser')[0].id = idUser + mask;
$('#txtPassword')[0].id = idPass + mask;
var idUserMasked= "#" + idUser + mask;
var idPassMasked= "#" + idPass + mask;
//deleting mask
//$(iduserMasked).attr("id", iduser);
//$(idPassMasked).attr("id", idPass);
//console.log("user id unmasked: " + $(txtUser).attr('id') );
//console.log("pass id unmasked: " + $(txtPassword).attr('id') );
});
</script>
No hay comentarios:
Publicar un comentario