Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN">
- <html>
- <head>
- <title>New Document</title>
- <meta http-equiv="content-type" content="text/html; charset=iso-8859-1">
- <style>
- button{
- background-image: linear-gradient(to bottom,#337ab7 0,#265a88 100%);
- color: white;
- padding: 10px 18px;
- border: none;
- cursor: pointer;
- width: auto;
- }
- #hidden input[type=text] {
- width: 200px;;
- padding: 12px 20px;
- margin: 8px 0;
- display: inline-block;
- border: 1px solid #ccc;
- box-sizing: border-box;
- }
- </style>
- </head>
- <body>
- <div id="hidden" style="display: none;">
- <input type="text" value="GUTSCHEINCODE123" id="gutschein" readonly>
- <button onClick="copy();">COPY</button>
- <button onClick="window.open('http://www.google.com')">Gutschein einlösen</button>
- </div>
- <button id="trigger" onClick="document.getElementById('hidden').style.display='block';document.getElementById('trigger').style.display='none'">Reveal</button>
- <script>
- function copy() {
- var copyText = document.getElementById("gutschein");
- copyText.select();
- document.execCommand("Copy");
- }
- </script>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement