The text below is selected, press Ctrl+C to copy to your clipboard. (⌘+C on Mac) No line numbers will be copied.
Guest
File
By Guest on 24th December 2023 07:19:08 PM | Syntax: HTML5 | Views: 189



New Paste New paste | Download Paste Download | Toggle Line Numbers Show/Hide line no. | Copy Paste Copy text to clipboard
  1. <!DOCTYPE html>
  2. <html lang="en">
  3.     <meta charset="UTF-8">
  4.     <meta name="viewport" content="width=device-width, initial-scale=1.0">
  5.     <link rel="stylesheet" href="style.css">
  6.     <title>Product Introduction</title>
  7. </head>
  8.     <header>
  9.         <h1>Lighter</h1>
  10.         <p>Making your Feature better!</p>
  11.     </header>
  12.  
  13.     <section id="productDetails">
  14.         <img src="https://th.bing.com/th/id/OIP.tVU_ep1ZXR1ONaJNoSUC5gHaHa?w=150&h=180&c=7&r=0&o=5&pid=1.7" alt="Product Image">
  15.         <div>
  16.             <h2>Lighter</h2>
  17.             <ul>
  18.                 <li>Make everything on your pov under control</li>
  19.                 <li>No electric needed</li>
  20.                 <li>Avoid your failure future</li>
  21.             </ul>
  22.         </div>
  23.     </section>
  24.  
  25.     <section id="pricing">
  26.         <h2> 999,999Usd</h2>
  27.         <p>Our product is available at an amazing price of $999,999. Don't miss out!</p>
  28.     </section>
  29.  
  30.     <section id="cta">
  31.         <h2>Get Yours Today!</h2>
  32.         <button onclick="openPurchaseForm()">Purchase Now</button>
  33.     </section>
  34.  
  35.     <div id="purchaseFormOverlay">
  36.         <div id="purchaseForm">
  37.             <span onclick="closePurchaseForm()" class="closeBtn">&times;</span>
  38.             <h2>Fill in your details</h2>
  39.             <form>
  40.                 <label for="name">Name:</label>
  41.                 <input type="text" id="name" name="name" required>
  42.  
  43.                 <label for="email">Email:</label>
  44.                 <input type="email" id="email" name="email" required>
  45.  
  46.                 <label for="address">Address:</label>
  47.                 <textarea id="address" name="address" rows="4" required></textarea>
  48.  
  49.                 <button type="button" onclick="submitPurchase()">Submit Purchase</button>
  50.             </form>
  51.         </div>
  52.     </div>
  53.    
  54.     <script src="script.js"></script>
  55. </body>
  56. </html>
  57.  
  58.  
  59.  
  60. css :
  61. body {
  62.     font-family: 'Arial', sans-serif;
  63.     margin: 0;
  64.     padding: 0;
  65.     box-sizing: border-box;
  66.     background-color: #f4f4f4;
  67. }
  68.  
  69. header {
  70.     background-color: #333;
  71.     color: #fff;
  72.     text-align: center;
  73.     padding: 20px;
  74. }
  75.  
  76. section {
  77.     margin: 20px;
  78.     background-color: #fff;
  79.     padding: 20px;
  80.     border-radius: 8px;
  81.     box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  82. }
  83.  
  84. #productDetails {
  85.     display: flex;
  86.     flex-wrap: wrap;
  87. }
  88.  
  89. #productDetails img {
  90.     max-width: 100%;
  91.     border: 1px solid #ccc;
  92.     border-radius: 8px;
  93.     margin-bottom: 20px;
  94. }
  95.  
  96. #productDetails div {
  97.     flex: 1;
  98.     margin-left: 20px;
  99. }
  100.  
  101. ul {
  102.     list-style-type: none;
  103.     padding: 0;
  104. }
  105.  
  106. ul li {
  107.     margin-bottom: 10px;
  108. }
  109.  
  110. ul li::before {
  111.     content: "\2022";
  112.     color: #333;
  113.     font-size: 16px;
  114.     margin-right: 5px;
  115. }
  116.  
  117.  
  118. button {
  119.     padding: 12px 24px;
  120.     font-size: 16px;
  121.     cursor: pointer;
  122.     background-color: #333;
  123.     color: #fff;
  124.     border: none;
  125.     border-radius: 4px;
  126.     transition: background-color 0.3s ease;
  127. }
  128.  
  129. button:hover {
  130.     background-color: #555;
  131. }
  132.  
  133. #purchaseFormOverlay {
  134.     display: none;
  135.     justify-content: center;
  136.     align-items: center;
  137.     position: fixed;
  138.     top: 0;
  139.     left: 0;
  140.     width: 100%;
  141.     height: 100%;
  142.     background-color: rgba(0, 0, 0, 0.5);
  143. }
  144.  
  145. #purchaseForm {
  146.     background-color: #fff;
  147.     padding: 20px;
  148.     border-radius: 8px;
  149.     box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  150. }
  151.  
  152. .closeBtn {
  153.     font-size: 24px;
  154.     font-weight: bold;
  155.     color: #777;
  156.     cursor: pointer;
  157.     position: absolute;
  158.     top: 10px;
  159.     right: 10px;
  160. }
  161.  
  162. form {
  163.     display: flex;
  164.     flex-direction: column;
  165. }
  166.  
  167. label {
  168.     margin-top: 10px;
  169.     font-weight: bold;
  170. }
  171.  
  172. input,
  173. textarea {
  174.     padding: 8px;
  175.     margin-top: 5px;
  176.     margin-bottom: 15px;
  177.     border: 1px solid #ccc;
  178.     border-radius: 4px;
  179. }
  180.  
  181. button[type="button"] {
  182.     background-color: #333;
  183.     color: #fff;
  184.     border: none;
  185.     padding: 12px 24px;
  186.     font-size: 16px;
  187.     cursor: pointer;
  188.     border-radius: 4px;
  189.     transition: background-color 0.3s ease;
  190. }
  191.  
  192. button[type="button"]:hover {
  193.     background-color: #555;
  194. }
  195.  
  196.  
  197. js :
  198. function openPurchaseForm() {
  199.     document.getElementById("purchaseFormOverlay").style.display = "flex";
  200. }
  201.  
  202. function closePurchaseForm() {
  203.     document.getElementById("purchaseFormOverlay").style.display = "none";
  204. }
  205.  
  206. function submitPurchase() {
  207.     alert('You got scammed!, thank for infomation');
  208.     closePurchaseForm();
  209. }





file    



css : body { font-family: 'Arial', sans-serif; margin: 0; padding: 0; box-sizing: border-box; background-color: #f4f4f4; } header { background-color: #333; color: #fff; text-align: center; padding: 20px; } section { margin: 20px; background-color: #fff; padding: 20px; border-radius: 8px; box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1); } #productDetails { display: flex; flex-wrap: wrap; } #productDetails img { max-width: 100%; border: 1px solid #ccc; border-radius: 8px; margin-bottom: 20px; } #productDetails div { flex: 1; margin-left: 20px; } ul { list-style-type: none; padding: 0; } ul li { margin-bottom: 10px; } ul li::before { content: "\2022"; color: #333; font-size: 16px; margin-right: 5px; } button { padding: 12px 24px; font-size: 16px; cursor: pointer; background-color: #333; color: #fff; border: none; border-radius: 4px; transition: background-color 0.3s ease; } button:hover { background-color: #555; } #purchaseFormOverlay { display: none; justify-content: center; align-items: center; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background-color: rgba(0, 0, 0, 0.5); } #purchaseForm { background-color: #fff; padding: 20px; border-radius: 8px; box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1); } .closeBtn { font-size: 24px; font-weight: bold; color: #777; cursor: pointer; position: absolute; top: 10px; right: 10px; } form { display: flex; flex-direction: column; } label { margin-top: 10px; font-weight: bold; } input, textarea { padding: 8px; margin-top: 5px; margin-bottom: 15px; border: 1px solid #ccc; border-radius: 4px; } button[type="button"] { background-color: #333; color: #fff; border: none; padding: 12px 24px; font-size: 16px; cursor: pointer; border-radius: 4px; transition: background-color 0.3s ease; } button[type="button"]:hover { background-color: #555; } js : function openPurchaseForm() { document.getElementById("purchaseFormOverlay").style.display = "flex"; } function closePurchaseForm() { document.getElementById("purchaseFormOverlay").style.display = "none"; } function submitPurchase() { alert('You got scammed!, thank for infomation'); closePurchaseForm(); }