summaryrefslogtreecommitdiff
path: root/Base/res/html
diff options
context:
space:
mode:
authorTimothy Flynn <trflynn89@pm.me>2021-04-11 10:42:58 -0400
committerAndreas Kling <kling@serenityos.org>2021-04-11 18:24:34 +0200
commit59e47c3b11a225674f6b31f041002e88cc08a57e (patch)
tree989616d12fb0839aa036b05f8acaa293e294bc3d /Base/res/html
parentfe8cefa7c1b056bb4097c4dce27a0304295d8429 (diff)
downloadserenity-59e47c3b11a225674f6b31f041002e88cc08a57e.zip
Base: Add test page for document.cookie
Diffstat (limited to 'Base/res/html')
-rw-r--r--Base/res/html/misc/cookie.html15
-rw-r--r--Base/res/html/misc/welcome.html1
2 files changed, 16 insertions, 0 deletions
diff --git a/Base/res/html/misc/cookie.html b/Base/res/html/misc/cookie.html
new file mode 100644
index 0000000000..1391bab3ff
--- /dev/null
+++ b/Base/res/html/misc/cookie.html
@@ -0,0 +1,15 @@
+<body>
+ <input type=button onclick="setCookie('cookie1=value1')" value="Set Cookie 1" />
+ <input type=button onclick="setCookie('cookie2=value2')" value="Set Cookie 2" />
+ <input type=button onclick="setCookie('cookie3=value3')" value="Set Cookie 3" />
+ <br /><pre id=cookies></pre>
+
+ <script>
+ function setCookie(cookie) {
+ document.cookie = cookie;
+ document.getElementById('cookies').innerHTML = document.cookie;
+ }
+
+ document.getElementById('cookies').innerHTML = document.cookie;
+ </script>
+</body>
diff --git a/Base/res/html/misc/welcome.html b/Base/res/html/misc/welcome.html
index da883339fe..e54552d00b 100644
--- a/Base/res/html/misc/welcome.html
+++ b/Base/res/html/misc/welcome.html
@@ -38,6 +38,7 @@ span#loadtime {
<p>This page loaded in <b><span id="loadtime"></span></b> ms</p>
<p>Some small test pages:</p>
<ul>
+ <li><a href="cookie.html">document.cookie</a></li>
<li><a href="last-of-type.html">CSS :last-of-type selector</a></li>
<li><a href="first-of-type.html">CSS :first-of-type selector</a></li>
<li><a href="background-repeat-test.html">background image with repetition rules</a></li>