chiark / gitweb /
htmlhead
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Tue, 4 Sep 2012 20:54:30 +0000 (21:54 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Tue, 4 Sep 2012 20:54:30 +0000 (21:54 +0100)
mason/edit
mason/htmlhead [new file with mode: 0644]
mason/main

index 60e8b9e..e887bdb 100755 (executable)
@@ -39,10 +39,7 @@ if ($ARGS{'create'}) {
 if (!$tx) { die "no such text $textid"; }
 
 </%perl>
-<html lang="en"><head>
-<title>Editing - <% $tx->{'desc'} |h %> - Email away message setup</title>
-</head><body>
-<h1>Edit "<% $tx->{'desc'} |h %>"</h1>
+<& htmlhead, subpage => "Edit \"$tx->{'desc'}\"" &>
 <form action="save" method="post">
 <&| txtable, tx => $tx, inputs => 1 &>
 <tr><td colspan=2><textarea cols=79 rows=15><%
diff --git a/mason/htmlhead b/mason/htmlhead
new file mode 100644 (file)
index 0000000..0a77460
--- /dev/null
@@ -0,0 +1,7 @@
+<%args>
+$subpage
+</%args><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
+<html lang="en"><head>
+<title><% $subpage |h %> - Email away message setup</title>
+</head><body>
+<h1><% $subpage |h %></h1>
index 42cfaac..206da10 100755 (executable)
@@ -3,10 +3,7 @@ use AwayMsg;
 db_connect();
 my ($sth,$row,$sthi,$rowi);
 </%init>
-<html lang="en"><head>
-<title>Email away message setup</title>
-</head><body>
-<h1>Email away message setup</h1>
+<&htmlhead, subpage => 'Overview'&>
 
 <h2>Email addresses and their configuration</h2>
 <%perl>