Guest User

Untitled

a guest
Oct 21st, 2018
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.36 KB | None | 0 0
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset='utf-8'>
  5. <title>404</title>
  6. <script type='text/javascript' src='//ajax.googleapis.com/ajax/libs/jquery/2.1.0/jquery.min.js'></script>
  7. <style type='text/css'>
  8. #canvas {
  9. position:absolute;
  10. z-index: -1;
  11. top: 0px;
  12. left: 0px;
  13. width: 100%;
  14. height: 100%;
  15. }
  16. h1 {
  17. text-align: center;
  18. font-size: 300px;
  19. color: red;
  20. }
  21. </style>
  22. <script type='text/javascript'>
  23. $(window).load(function() {
  24. var width = canvas.width = $(document).width();
  25. var height = canvas.height = $(document).height();
  26. var letters = Array(256).join(1).split('');
  27. var draw = function () {
  28. canvas.getContext('2d').fillStyle = 'rgba(0,0,0,.05)';
  29. canvas.getContext('2d').fillRect(0, 0, width, height);
  30. canvas.getContext('2d').fillStyle = '#0e0';
  31. letters.map(function (y_pos, index) {
  32. text = String.fromCharCode(65 + Math.random() * 33);
  33. x_pos = index * 10;
  34. canvas.getContext('2d').fillText(text, x_pos, y_pos);
  35. letters[index] = (y_pos > 758 + Math.random() * 1e4) ? 0 : y_pos + 10;
  36. });
  37. };
  38. setInterval(draw, 33);
  39. });
  40. </script>
  41. </head>
  42. <body>
  43. <canvas id='canvas'></canvas>
  44. <h1>404</h1>
  45. </body>
  46. </html>
Add Comment
Please, Sign In to add comment