aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Kavon <me+git@alexkavon.com>2025-07-02 14:43:11 -0400
committerAlexander Kavon <me+git@alexkavon.com>2025-07-02 14:43:11 -0400
commit9424f9c207ed3f270465250c0fcb5bf49e59c0c0 (patch)
tree203b95d45268928969672c17821630e8a3676b27
parent2643184be41f577e3c19d762894b26667560bbe3 (diff)
add head.xsl template, make Caddyfile work, add pure.css dev import
-rw-r--r--Caddyfile5
-rw-r--r--static/contact.xsl20
-rw-r--r--static/head.xsl6
3 files changed, 25 insertions, 6 deletions
diff --git a/Caddyfile b/Caddyfile
index 27b58a4..fc56984 100644
--- a/Caddyfile
+++ b/Caddyfile
@@ -1,7 +1,8 @@
:8080
+root static
try_files {path}.xml {path}.html
file_server {
- index index.xml index.html
- root static
+ root static
+ index index.xml index.html
}
diff --git a/static/contact.xsl b/static/contact.xsl
index e9ce03c..56624f1 100644
--- a/static/contact.xsl
+++ b/static/contact.xsl
@@ -1,16 +1,28 @@
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="html" indent="yes" />
+ <xsl:include href="head.xsl" />
<xsl:template match="/">
<html>
<head>
+ <xsl:call-template name="head" />
<title>Contact</title>
</head>
<body>
- <form id="contact-form">
- <input type="text" name="name" />
- <input type="email" name="email" />
- <textarea name="message"></textarea>
+ <h1>Contact</h1>
+ <form id="contact-form" class="pure-form pure-form-stacked">
+ <label for="name_in">
+ Name
+ <input id="name_in" type="text" name="name" />
+ </label>
+ <label for="email_in">
+ Email
+ <input id="email_in" type="email" name="email" />
+ </label>
+ <label for="message_in">
+ Message
+ <textarea id="message_in" name="message"></textarea>
+ </label>
</form>
</body>
</html>
diff --git a/static/head.xsl b/static/head.xsl
new file mode 100644
index 0000000..189497e
--- /dev/null
+++ b/static/head.xsl
@@ -0,0 +1,6 @@
+<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
+ <xsl:template name="head">
+ <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/purecss@3.0.0/build/pure-min.css" integrity="sha384-X38yfunGUhNzHpBaEBsWLO+A0HDYOQi8ufWDkZ0k9e0eXz/tH3II7uKZ9msv++Ls" crossorigin="anonymous" />
+ <meta name="viewport" content="width=device-width, initial-scale=1" />
+ </xsl:template>
+</xsl:stylesheet>