-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
28 lines (25 loc) · 842 Bytes
/
Copy pathindex.html
File metadata and controls
28 lines (25 loc) · 842 Bytes
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>HTTP Request Details</title>
</head>
<body>
<h1>HTTP Request Details</h1>
<h3>Request Headers:</h3>
<pre id="headers"></pre>
<h3>Query Parameters:</h3>
<pre id="queryParams"></pre>
<script>
try {
const headers = JSON.stringify(Object.fromEntries(new Headers(location.search).entries()), null, 2);
document.getElementById('headers').textContent = headers;
} catch {
// ignore
}
const queryParams = JSON.stringify(Object.fromEntries(new URLSearchParams(location.search).entries()), null, 2);
document.getElementById('queryParams').textContent = queryParams;
</script>
</body>
</html>