-
Notifications
You must be signed in to change notification settings - Fork 14
Expand file tree
/
Copy pathindex.html
More file actions
242 lines (220 loc) · 6.6 KB
/
Copy pathindex.html
File metadata and controls
242 lines (220 loc) · 6.6 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
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Mepo Learn</title>
<style>
html {
overflow-x: hidden;
}
body {
font-family: Arial, sans-serif;
margin: 0;
padding: 0;
background-color: #121212;
color: #ffffff;
z-index: 1;
}
.title {
text-align: center;
font-size: 5rem;
font-weight: bold;
color: white;
text-shadow:
3px 3px 5px rgba(255, 0, 0, 0.8),
-3px -3px 5px rgba(0, 0, 255, 0.8),
0px 0px 20px rgba(255, 255, 255, 1);
font-family: 'Arial', sans-serif;
}
/* Background Wave Effect */
.background-wave {
position: absolute;
top: -50%;
left: -50%;
width: 200%;
height: 200%;
background: linear-gradient(135deg, rgba(0, 0, 139, 0.2), rgba(0, 0, 139, 0.4), transparent);
animation: waveEffect 8s infinite ease-in-out;
z-index: -1; /* Make sure it's behind all other content */
}
@keyframes waveEffect {
0% {
top: -50%;
left: -50%;
opacity: 0.3;
}
10% {
top: -47%;
left: -47%;
opacity: 0.35;
}
20% {
top: -43%;
left: -43%;
opacity: 0.4;
}
30% {
top: -40%;
left: -40%;
opacity: 0.45;
}
40% {
top: -35%;
left: -35%;
opacity: 0.5;
}
50% {
top: -30%;
left: -30%;
opacity: 0.55;
}
60% {
top: -35%;
left: -35%;
opacity: 0.5;
}
70% {
top: -40%;
left: -40%;
opacity: 0.45;
}
80% {
top: -43%;
left: -43%;
opacity: 0.4;
}
90% {
top: -47%;
left: -47%;
opacity: 0.35;
}
100% {
top: -50%;
left: -50%;
opacity: 0.3;
}
}
.container {
max-width: 900px;
margin: auto;
padding: 20px;
text-align: center;
}
h1 {
margin-bottom: 20px;
}
.search-bar {
margin: 20px 0;
}
.search-bar input {
width: 70%;
padding: 10px;
border-radius: 5px;
border: 1px solid #444;
font-size: 16px;
}
.search-bar button {
padding: 10px 20px;
margin-left: 10px;
border: none;
border-radius: 5px;
background-color: #444;
color: #fff;
font-size: 16px;
cursor: pointer;
}
.search-bar button:hover {
background-color: #555;
}
.game-frame-container {
margin-top: 20px;
display: none; /* Initially hidden */
position: relative;
width: 100%;
height: 600px;
overflow: hidden;
}
#fullscreen-button {
position: absolute;
top: 10px;
right: 10px;
z-index: 10;
width: 40px;
height: 40px;
background-color: #444;
color: #fff;
border: none;
border-radius: 8px;
cursor: pointer;
transition: background-color 0.3s ease;
font-size: 24px;
display: flex;
justify-content: center;
align-items: center;
}
#fullscreen-button:hover {
background-color: #555;
}
#game-frame {
width: 100%;
height: 100%;
border: none;
}
</style>
</head>
<body>
<div class="background-wave"></div> <!-- Background wave effect added here -->
<div class="container">
<h1 class="title">MepoHub</h1>
<p>Enter a URL to proxy and load:</p>
<!-- Search Bar -->
<div class="search-bar">
<input type="text" id="url-input" placeholder="Enter the URL you want to proxy..." />
<button onclick="loadURL()">Load</button>
</div>
<!-- Game Embed Frame Container -->
<div class="game-frame-container" id="game-frame-container">
<iframe id="game-frame"></iframe>
<button id="fullscreen-button" onclick="toggleFullScreen()">⛶</button>
</div>
</div>
<script>
// Function to load the URL entered in the search bar
function loadURL() {
const urlInput = document.getElementById('url-input');
const gameFrameContainer = document.getElementById('game-frame-container');
const gameFrame = document.getElementById('game-frame');
// Validate the URL input
if (!urlInput.value) {
alert('Please enter a URL.');
return;
}
try {
const encodedUrl = encodeURIComponent(urlInput.value); // Encode the URL
gameFrame.src = `/proxy?target=${encodedUrl}`; // Pass the URL to the proxy
gameFrameContainer.style.display = 'block'; // Show the iframe
} catch (error) {
alert('Invalid URL. Please try again.');
console.error('URL Parsing Error:', error);
}
}
function toggleFullScreen() {
const gameFrameContainer = document.getElementById('game-frame-container');
if (!document.fullscreenElement) {
gameFrameContainer.requestFullscreen().catch((err) => {
alert(`Error attempting to enable fullscreen mode: ${err.message}`);
});
} else {
document.exitFullscreen();
}
}
// Trigger loadURL on Enter key press
document.getElementById('url-input').addEventListener('keydown', (event) => {
if (event.key === 'Enter') {
loadURL(); // Trigger loadURL on Enter key
}
});
</script>
</body>
</html>