-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathhtml.txt
More file actions
195 lines (192 loc) · 6.86 KB
/
html.txt
File metadata and controls
195 lines (192 loc) · 6.86 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
<html>
<head>
<script src="https://cdn.tailwindcss.com">
</script>
<link href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.3/css/all.min.css" rel="stylesheet"/>
<script>
function showAddressForm() {
document.getElementById('product-page').classList.add('hidden');
document.getElementById('address-form').classList.remove('hidden');
}
function showPaymentPage() {
document.getElementById('address-form').classList.add('hidden');
document.getElementById('payment-page').classList.remove('hidden');
}
function showOrderConfirmation() {
document.getElementById('payment-page').classList.add('hidden');
document.getElementById('order-confirmation').classList.remove('hidden');
sendWhatsAppMessage();
}
function sendWhatsAppMessage() {
const name = document.getElementById('name').value;
const address = document.getElementById('address').value;
const country = document.getElementById('country').value;
const state = document.getElementById('state').value;
const village = document.getElementById('village').value;
const mobile = document.getElementById('mobile').value;
const message = `Order Details:\nName: ${name}\nAddress: ${address}\nCountry: ${country}\nState: ${state}\nVillage: ${village}\nMobile: ${mobile}`;
const whatsappUrl = `https://wa.me/918767244752?text=${encodeURIComponent(message)}`;
window.open(whatsappUrl, '_blank');
}
</script>
</head>
<body class="bg-white">
<div class="max-w-md mx-auto">
<!-- Product Page -->
<div id="product-page">
<!-- Header -->
<div class="flex items-center justify-between p-4">
<i class="fas fa-arrow-left text-xl">
</i>
<div class="flex items-center space-x-4">
<i class="fas fa-search text-xl">
</i>
<div class="relative">
<i class="fas fa-shopping-cart text-xl">
</i>
<span class="absolute top-0 right-0 bg-red-500 text-white text-xs rounded-full px-1.5">
15
</span>
</div>
</div>
</div>
<!-- Product Info -->
<div class="p-4">
<div class="flex justify-between items-center">
<div>
<p class="text-gray-600">
पुरुषांसाठी काळा ट्रॅक पॅंट्स
</p>
<div class="flex items-center space-x-2">
<p class="text-green-600 text-lg font-bold">
67%
</p>
<p class="line-through text-gray-500">
1,399
</p>
<p class="text-black text-lg font-bold">
₹449
</p>
</div>
</div>
<p class="text-gray-400">
Sponsored
</p>
</div>
<!-- Product Image -->
<div class="my-4">
<img alt="A bottle of Mountain Dew with green leaves in the background" class="w-full" height="800" src="https://storage.googleapis.com/a1aa/image/bZ4sOJWjLoYPANcCid2jRGjxBWsCPrkOFQ4sXCS09fTA462JA.jpg" width="600"/>
</div>
<!-- Product Description -->
<p class="text-gray-800 text-lg">
मराठी माणसाचा आवड असलेला ब्रँड.
</p>
<!-- Price and Discount -->
<div class="flex justify-between items-center my-4">
<div>
<p class="text-gray-600">
पुरुषांसाठी काळा ट्रॅक पॅंट्स
</p>
<div class="flex items-center space-x-2">
<p class="text-green-600 text-lg font-bold">
67%
</p>
<p class="line-through text-gray-500">
1,399
</p>
<p class="text-black text-lg font-bold">
₹449
</p>
</div>
</div>
</div>
<!-- Buttons -->
<div class="flex space-x-4">
<button class="flex-1 bg-black text-white py-2 rounded">
कार्टमध्ये टाका
</button>
<button class="flex-1 bg-yellow-500 text-black py-2 rounded" onclick="showAddressForm()">
आता खरेदी करा
</button>
</div>
</div>
</div>
<!-- Address Form -->
<div class="hidden p-4" id="address-form">
<h2 class="text-xl font-bold mb-4">
Enter Address Details
</h2>
<form>
<div class="mb-4">
<label class="block text-gray-700">
Name
</label>
<input class="w-full border border-gray-300 p-2 rounded" id="name" placeholder="Enter your name" type="text"/>
</div>
<div class="mb-4">
<label class="block text-gray-700">
Address
</label>
<input class="w-full border border-gray-300 p-2 rounded" id="address" placeholder="Enter your address" type="text"/>
</div>
<div class="mb-4">
<label class="block text-gray-700">
Country
</label>
<input class="w-full border border-gray-300 p-2 rounded" id="country" placeholder="Enter your country" type="text"/>
</div>
<div class="mb-4">
<label class="block text-gray-700">
State
</label>
<input class="w-full border border-gray-300 p-2 rounded" id="state" placeholder="Enter your state" type="text"/>
</div>
<div class="mb-4">
<label class="block text-gray-700">
Village
</label>
<input class="w-full border border-gray-300 p-2 rounded" id="village" placeholder="Enter your village" type="text"/>
</div>
<div class="mb-4">
<label class="block text-gray-700">
Mobile Number
</label>
<input class="w-full border border-gray-300 p-2 rounded" id="mobile" placeholder="Enter your mobile number" type="text"/>
</div>
<button class="w-full bg-yellow-500 text-black py-2 rounded" onclick="showPaymentPage()" type="button">
Proceed to Payment
</button>
</form>
</div>
<!-- Payment Page -->
<div class="hidden p-4" id="payment-page">
<h2 class="text-xl font-bold mb-4">
Payment Options
</h2>
<div class="mb-4">
<label class="block text-gray-700">
Select Payment Method
</label>
<div class="flex items-center space-x-2">
<input class="h-4 w-4" id="cod" name="payment" type="radio"/>
<label class="text-gray-700" for="cod">
Cash on Delivery
</label>
</div>
</div>
<button class="w-full bg-yellow-500 text-black py-2 rounded" onclick="showOrderConfirmation()" type="button">
Place Order
</button>
</div>
<!-- Order Confirmation -->
<div class="hidden p-4" id="order-confirmation">
<h2 class="text-xl font-bold mb-4">
Order Submitted
</h2>
<p class="text-gray-700">
Thank you for your order!
</p>
</div>
</div>
</body>
</html>