popup alert once a day

popup alert once a day

Hi,
I am trying to popup an alert once a day, but it does not work, long time I did not touch jquery, I feel I am lost, thanks, your help is appreciated.

Here is what I did :

  1. <html>
  2. <head>

  3.    <link rel="stylesheet" href="reveal.css">
  4.    <script type="text/javascript" src="http://code.jquery.com/jquery-1.6.min.js"></script>
  5. <script type="text/javascript" src="jquery.reveal.js"></script>
  6.    
  7.    <script type="text/javascript">
  8.    $(document).ready(function() {
  9.       if ( localStorage.getItem('seen') != (new Date()).getDate()) {
  10.         setTimeout(showpanel, 4000);
  11.     }
  12.       $("div").click(function() {
  13.         alert("Wel-Come to the Learn jQuery..!");
  14.       });

  15. function showpanel() {
  16.     $('.reveal-modal').reveal({
  17.         animation: 'fade',
  18.         animationspeed: 800
  19.     });

  20.     localStorage.setItem('seen', (new Date()).getDate());
  21. }
  22.   
  23.   
  24.    });
  25.    </script>
  26. </head>
  27. <body>
  28. <div id="ex1">
  29. Click here to open Dialogue Box.
  30. </div>
  31. <div id="myModal" class="reveal-modal">
  32. <h1>Reveal Modal Goodness</h1>
  33. <p>This is a default modal in all its glory, but any of the styles here can easily be changed in the CSS.</p>
  34. <a class="close-reveal-modal">&#215;</a>
  35. </div>
  36. </body>
  37. </html>

  38. Thanks,