3
I wanted to put a password on the page when it is accessed(simple), in a window (Alert type) with password that appears before loading the page, I wanted this custom "Alert" like a modal or any custom window...
very simple even people is childish page...
code I’m using:
<script language=javascript>
senha = '123456';
senhadig = prompt("Digite a senha","")
if (senha != senhadig){
top.location.href='erro.html';
}
</script>
Important that you can not see the background before entering the correct password...
As above but wanted to leave customized, can be with jquery, I’ve looked on sites about dialog boxes but could not...
I am not worried about safety, it is for small children (students), for they do not advance without permission. but I put in unescape and use noscript =D
If you already know it could be a modal, why don’t you try doing it using a modal?
– Woss
'cause I can’t put a password code in the modal, just a window
– Lary