summaryrefslogtreecommitdiff
path: root/Base/home
diff options
context:
space:
mode:
authorAndreas Kling <kling@serenityos.org>2020-04-03 18:10:20 +0200
committerAndreas Kling <kling@serenityos.org>2020-04-03 18:12:20 +0200
commita2b0cc8f08f5f082bbbf3f2c73cf8b2d2115ede9 (patch)
tree57c1daafedbbd349cf96f74c3f4d4872595ae76e /Base/home
parent6e5f9e20eb3a5603089395f304bcf7fee38266fc (diff)
downloadserenity-a2b0cc8f08f5f082bbbf3f2c73cf8b2d2115ede9.zip
LibWeb: Add "navigator" object and expose navigator.userAgent
A lot of web content looks for this property. We'll probably have to tweak this as we go, but at least now we have it. :^)
Diffstat (limited to 'Base/home')
-rw-r--r--Base/home/anon/www/welcome.html9
1 files changed, 8 insertions, 1 deletions
diff --git a/Base/home/anon/www/welcome.html b/Base/home/anon/www/welcome.html
index 01a80d67f7..3084977afe 100644
--- a/Base/home/anon/www/welcome.html
+++ b/Base/home/anon/www/welcome.html
@@ -16,11 +16,18 @@ body {
h1 {
color: #a00;
}
+span#ua {
+ color: red;
+}
</style>
+<script>
+document.getElementById("ua").innerHTML = navigator.userAgent;
+</script>
</head>
<body link="#44f" vlink="#c4c" background="90s-bg.png">
<h1>Welcome to the Serenity Browser!</h1>
- <p>This is a very simple browser built on the LibWeb engine.</p>
+ <p>This is a very simple browser built on the LibWeb and LibJS engines.</p>
+ <p>Your user agent is: <span id="ua"></span></p>
<p>Some small test pages:</p>
<ul>
<li><a href="qsa.html">querySelectorAll test</a></li>