if Util.validEmail dom then
val id = MailingList.add (Init.getUserId(), dom, $"msg");
if not (MailingList.notifyNew id) then
- %><h3><b>Error sending e-mail notification</b></h3><%
+ %><h3>Error sending e-mail notification</h3><%
end
- %><h3><b>Request added</b></h3><%
+ %><h3>Request added</h3><%
else
- %><h3><b>Invalid list e-mail address</b></h3><%
+ %><h3>Invalid list e-mail address</h3><%
end
elseif $"cmd" = "open" then
- %><h3><b>Open requests</b></h3>
+ %><h3>Open requests</h3>
<a href="list?cmd=list">List all requests</a><%
foreach (name, req) in MailingList.listOpen () do %>
<br><hr><br>
-<table>
-<tr> <td align="right"><b>By</b>:</td> <td><a href="user?id=<% #usr req %>"><% name %></a></td> </tr>
-<tr> <td align="right"><b>Time</b>:</td> <td><% #stamp req %></td> </tr>
-<tr> <td align="right"><b>List name</b>:</td> <td><% #data req %></td> </tr>
-<tr> <td align="right" valign="top"><b>Reason</b>:</td> <td colspan="2"><% Web.html (#msg req) %></td> </tr>
+<table class="blanks">
+<tr> <td>By:</td> <td><a href="user?id=<% #usr req %>"><% name %></a></td> </tr>
+<tr> <td>Time:</td> <td><% #stamp req %></td> </tr>
+<tr> <td>List name:</td> <td><% #data req %></td> </tr>
+<tr> <td>Reason:</td> <td colspan="2"><% Web.html (#msg req) %></td> </tr>
</table>
-<% if admin then %>
+<% if admin then
+ val (user, dom) = MailingList.listWebHost (#data req) %>
<br>
<a href="list?mod=<% #id req %>">[Modify]</a>
<a href="list?del=<% #id req %>">[Delete]</a><br>
- To set up, run: <tt>newlist <% #data req %> <% name %>@hcoop.net <% Util.randomPassword () %></tt>
+ To set up, run: <tt>listnew <% user %> <% dom %> <% name %> <% Util.randomPassword () %></tt>
<% end %>
<% end
elseif $"cmd" = "list" then
- %><h3><b>All requests</b></h3><%
+ %><h3>All requests</h3><%
foreach (name, req) in MailingList.list () do %>
<br><hr><br>
-<table>
-<tr> <td align="right"><b>By</b>:</td> <td colspan="2"><a href="user?id=<% #usr req %>"><% name %></a></td> </tr>
-<tr> <td align="right"><b>Time</b>:</td> <td colspan="2"><% #stamp req %></td> </tr>
-<tr> <td align="right"><b>List name</b>:</td> <td><% #data req %></td> </tr>
-<tr> <td align="right" valign="top"><b>Reason</b>:</td> <td colspan="2"><% Web.html (#msg req) %></td> </tr>
+<table class="blanks">
+<tr> <td>By:</td> <td colspan="2"><a href="user?id=<% #usr req %>"><% name %></a></td> </tr>
+<tr> <td>Time:</td> <td colspan="2"><% #stamp req %></td> </tr>
+<tr> <td>List name:</td> <td><% #data req %></td> </tr>
+<tr> <td>Reason:</td> <td colspan="2"><% Web.html (#msg req) %></td> </tr>
</table>
<% if admin then %>
val id = Web.stoi ($"mod");
val req = MailingList.lookup id;
val user = Init.lookupUser (#usr req) %>
-<h3><b>Handle request</b></h3>
+<h3>Handle request</h3>
-<form action="list">
+<form action="list" method="post">
<input type="hidden" name="save" value="<% id %>">
-<table>
-<tr> <td align="right"><b>Requestor</b>:</td> <td><a href="user?id=<% #usr req %>"><% #name user %></a></td> </tr>
-<tr> <td align="right"><b>Time</b>:</td> <td><% #stamp req %></td> </tr>
-<tr> <td align="right"><b>Status</b>:</td> <td><select name="status">
+<table class="blanks">
+<tr> <td>Requestor:</td> <td><a href="user?id=<% #usr req %>"><% #name user %></a></td> </tr>
+<tr> <td>Time:</td> <td><% #stamp req %></td> </tr>
+<tr> <td>Status:</td> <td><select name="status">
<option value="0"<% if #status req = MailingList.NEW then %> selected<% end %>>New</option>
<option value="1"<% if #status req = MailingList.INSTALLED then %> selected<% end %>>Installed</option>
<option value="2"<% if #status req = MailingList.REJECTED then %> selected<% end %>>Rejected</option>
</select></td> </tr>
-<tr> <td align="right"><b>List name</b>:</td> <td><input name="dom" value="<% #data req %>"></td> </tr>
-<tr> <td align="right" valign="top"><b>Message</b>:</td> <td><textarea name="msg" rows="10" cols="80" wrap="soft"><% Web.html (#msg req) %></textarea></td> </tr>
+<tr> <td>List name:</td> <td><input name="dom" value="<% #data req %>"></td> </tr>
+<tr> <td>Message:</td> <td><textarea name="msg" rows="10" cols="80" wrap="soft"><% Web.html (#msg req) %></textarea></td> </tr>
<tr> <td><input type="submit" value="Save"></td> </tr>
</table>
</form>
MailingList.modify {req with data = $"dom", msg = $"msg", status = newStatus};
if oldStatus <> newStatus then
if not (MailingList.notifyMod (oldStatus, newStatus, Init.getUserName(), id)) then
- %><h3><b>Error sending e-mail notification</b></h3><%
+ %><h3>Error sending e-mail notification</h3><%
end
end
- %><h3><b>Request modified</b></h3>
+ %><h3>Request modified</h3>
Back to: <a href="list?cmd=open">open requests</a>, <a href="list?cmd=list">all requests</a>
<% elseif $"del" <> "" then
val id = Web.stoi ($"del");
val req = MailingList.lookup id;
val user = Init.lookupUser (#usr req)
- %><h3><b>Are you sure you want to delete request by <% #name user %> for <tt><% #data req %></tt>?</b></h3>
+ %><h3>Are you sure you want to delete request by <% #name user %> for <tt><% #data req %></tt>?</h3>
<a href="list?del2=<% id %>">Yes, I'm sure!</a>
<% elseif $"del2" <> "" then
Group.requireGroupName "lists";
val id = Web.stoi ($"del2");
MailingList.delete id
- %><h3><b>Request deleted</b><h3>
+ %><h3>Request deleted</b><h3>
Back to: <a href="list?cmd=open">open requests</a>, <a href="list?cmd=list">all requests</a>
<% else %>
-<h3><b>Request new mailing list</b></h3>
+<h3>Request new mailing list</h3>
+
+<p>Enter here the e-mail address you would like for your list. Please keep in mind that the part of your list address before the "@" must be unique across all mailing lists we run. We may reject applications with overly general names here, especially names of current users or UNIX usernames that are likely to be chosen by future members. The "Reason" field is optional.</p>
-Enter here the e-mail address you would like for your list. Please keep in mind that the part of your list address before the "@" must be unique across all mailing lists we run. We may reject applications with overly general names here, especially names of current users or UNIX usernames that are likely to be chosen by future members. The "Reason" field is optional.
+<p>If you want to use the Mailman web interface on your new list, and you want this to appear on a different web virtual host than hcoop.net, you should create a file <tt>.mailman</tt> in the domtool directory for this domain and run <tt>domtool</tt>, before submitting a request. In that file, put the hostname of the vhost you want to use, and be sure to include a <tt>Mailman</tt> directive in that vhost's configuration.</p>
-<form action="list">
-<table>
-<tr> <td align="right" valign="top"><b>List name</b>:</td> <td><input name="req"></td> </tr>
-<tr> <td align="right" valign="top"><b>Reason</b>:</td> <td><textarea name="msg" rows="5" cols="80" wrap="soft"></textarea></td> </tr>
+<form action="list" method="post">
+<table class="blanks">
+<tr> <td>List name:</td> <td><input name="req"></td> </tr>
+<tr> <td>Reason:</td> <td><textarea name="msg" rows="5" cols="80" wrap="soft"></textarea></td> </tr>
<tr> <td><input type="submit" value="Request"></td> </tr>
</table>
</form>