BrU32

Fake Bar Code Maker With Custom Color Options V1 SRC

Jul 11th, 2016
129
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.49 KB | None | 0 0
  1. <body bgcolor="#FFFFFF">
  2. </script>
  3. <html>
  4. <body onmousemove="drawe();" onchange="drawe();" background-color="white">
  5. <canvas id="myCanvas" width="1000" height="1000" style="background:white;color:red;">
  6. </canvas>
  7. <script>
  8. var p=prompt("Enter Color:");
  9. function drawe(){
  10. var canvas = document.getElementById("myCanvas");
  11. var ctx = canvas.getContext("2d");
  12. ctx.strokeStyle =p;
  13. ctx.moveTo(event.x,0);
  14. ctx.lineTo(event.x,1000);
  15. ctx.stroke();
  16. ctx.clear();
  17. }
  18. </script>
  19. </body>
  20. </html>
Advertisement
Add Comment
Please, Sign In to add comment