-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
121 lines (120 loc) · 4.1 KB
/
index.html
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Multi-Search</title>
<link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;500&display=swap">
<style>
body {
font-family: 'Roboto', sans-serif;
display: flex;
flex-wrap: wrap;
justify-content: center;
align-items: center;
min-height: 100vh;
margin: 0;
background-color: #121212;
color: #ffffff;
padding: 20px;
box-sizing: border-box;
}
.container {
background: #1e1e1e;
padding: 20px;
border-radius: 10px;
box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.3);
text-align: center;
width: 100%;
max-width: 400px;
}
input {
width: 100%;
padding: 12px;
margin: 10px 0;
border: none;
border-radius: 5px;
font-size: 16px;
outline: none;
background: #333;
color: white;
box-sizing: border-box;
}
.btn-container {
display: flex;
flex-wrap: wrap;
gap: 10px;
justify-content: center;
}
button {
background: #6200ea;
border: none;
padding: 12px 20px;
border-radius: 5px;
color: white;
font-size: 16px;
cursor: pointer;
transition: background 0.3s;
}
button:hover {
background: #3700b3;
}
@media (min-width: 768px) {
.container {
width: 350px;
}
}
</style>
</head>
<body>
<div class="container">
<h2>Multi-Search Engine</h2>
<input type="text" id="searchQuery" placeholder="Enter your search query">
<div class="btn-container">
<button onclick="search('google')">Google</button>
<button onclick="search('youtube')">YouTube</button>
<button onclick="search('maps')">Google Maps</button>
<button onclick="search('brave')">Brave Search</button>
<button onclick="search('chatgpt')">ChatGPT</button>
<button onclick="search('amazon')">Amazon</button>
<button onclick="search('flipkart')">Flipkart</button>
<button onclick="search('myntra')">Myntra</button>
</div>
</div>
<script>
function search(engine) {
let query = document.getElementById('searchQuery').value;
if (query.trim() === '') return;
let url = '';
switch(engine) {
case 'google':
url = `https://www.google.com/search?q=${encodeURIComponent(query)}`;
break;
case 'youtube':
url = `https://www.youtube.com/results?search_query=${encodeURIComponent(query)}`;
break;
case 'maps':
url = `https://www.google.com/maps/search/${encodeURIComponent(query)}`;
break;
case 'brave':
url = `https://search.brave.com/search?q=${encodeURIComponent(query)}`;
break;
case 'chatgpt':
url = `https://chat.openai.com/?q=${encodeURIComponent(query)}`;
break;
case 'amazon':
url = `https://www.amazon.com/s?k=${encodeURIComponent(query)}`;
break;
case 'flipkart':
url = `https://www.flipkart.com/search?q=${encodeURIComponent(query)}`;
break;
case 'myntra':
url = `https://www.myntra.com/${encodeURIComponent(query)}`;
break;
}
window.open(url, '_blank');
document.getElementById('searchQuery').value = '';
}
</script>
</body>
</html>