Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <html lang="en-US">
- <head>
- <script src="jquery-1.9.1.min.js"></script>
- <script type="text/javascript">
- $(document).ready(function(){
- $("#simpan").click(function(){
- $("#simpan").hide();
- $("#timer").show();
- });
- });
- </script>
- <script type="text/javascript">
- $(document).ready(function(){
- $("#simpan").click(function(){
- var detik = 10;
- function hitung(){
- var to = setTimeout(hitung,1000);
- var peringatan = 'style = "color: red"';
- $('#timer').html( '<h1 align="center" '+peringatan+'>Please Wait<br />'+detik+'</h1>' );
- detik --;
- if(detik < 0){
- clearTimeout(to);
- detik = 10;
- $("#timer").hide();
- $("#simpan").show();
- }
- }
- hitung();
- });
- });
- </script>
- </head>
- <body>
- <center>
- <form action="">
- User : <input type="text" /><br /><br />
- Password : <input type="text" /><br /><br />
- status : <input type="text" /><br /><br />
- <input type="button" value="Submit" id="simpan" />
- <div id="timer" style="display:none;"></div>
- </form>
- </center>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement