A tumblelog CMS built on AJAX, PHP and MySQL.

template_bm.htm 1.8KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  2. "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  3. <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
  4. <head>
  5. <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
  6. <title>gelato bookmarklet</title>
  7. <style type="text/css">
  8. body {
  9. background-color: #e1e1e1;
  10. margin: 0px;
  11. font: Normal 15px 'Trebuchet MS',Verdana,Helvetica,sans-serif;
  12. text-align: center;
  13. }
  14. div#content {
  15. margin: 137px 30px 0px 30px;
  16. padding: 15px;
  17. }
  18. </style>
  19. <script type="text/javascript">
  20. function countdown_func() {
  21. var prefix = 'or wait ';
  22. countdown--;
  23. el = document.getElementById('countdown');
  24. if (countdown == 1) {
  25. el.firstChild.nodeValue =
  26. prefix + countdown + ' second.';
  27. } else if (countdown > 0) {
  28. el.firstChild.nodeValue =
  29. prefix + countdown + ' seconds.';
  30. } else {
  31. self.close();
  32. }
  33. if (countdown > 0) setTimeout('countdown_func()', 1000);
  34. }
  35. var countdown = 3;
  36. </script>
  37. </head>
  38. <body>
  39. <div id="content">
  40. <div style="margin-bottom:10px; font-size:40px; color:#777;">Done!</div>
  41. <a href="#" onclick="javascript:self.close(); return false;"
  42. style="color:#777;">Close this window</a>
  43. <span id="countdown" style="color:#777;">
  44. or wait 3 seconds.
  45. </span>
  46. </div>
  47. <script type="text/javascript">
  48. setTimeout('countdown_func()', 1000);
  49. </script>
  50. </body>
  51. </html>