27 lines
799 B
HTML
27 lines
799 B
HTML
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<title>Local Site — Form Target</title>
|
|
<link rel="stylesheet" href="assets/site.css">
|
|
</head>
|
|
<body>
|
|
<header>
|
|
<h1>Form Target</h1>
|
|
<nav><a href="index.html">Home</a> | <a href="form.html">Back to form</a></nav>
|
|
</header>
|
|
<main>
|
|
<p>The form submitted to this page. On a local file:// URL, GET forms
|
|
should append a query string to the URL; POST forms have no server
|
|
to receive the body, so the body is effectively dropped.</p>
|
|
<p>Current URL: <span id="url"></span></p>
|
|
<p>Query string: <span id="qs"></span></p>
|
|
</main>
|
|
<script>
|
|
var u = new URL(location.href);
|
|
document.getElementById('url').textContent = location.href;
|
|
document.getElementById('qs').textContent = u.search || '(none)';
|
|
</script>
|
|
</body>
|
|
</html>
|