summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorklm1998-03-30 23:52:25 +0000
committerklm1998-03-30 23:52:25 +0000
commitcb2f2143c5abc581907f4c08dfbcc928ca580d06 (patch)
treef6ac7a1892c38c2765c9f0277e0467b8be8104fb
parent6f0fda579aea9fa44f268bc0cbf922b95ee6e1fe (diff)
downloadmailman-cb2f2143c5abc581907f4c08dfbcc928ca580d06.tar.gz
mailman-cb2f2143c5abc581907f4c08dfbcc928ca580d06.tar.zst
mailman-cb2f2143c5abc581907f4c08dfbcc928ca580d06.zip
The double-use of the 'subscribe' cgi script for subscription and
edit-options had a hidden problem - entering info in the edit-options "info" field with a carriage return (in netscape, at least) resulted in doing the default subscribe submit, which would get rejected due to lack of email and password. For now i've just elaborated the check for edit-options to look additionally (besides checking for the right submit button having been hit) for the presence of a value in the edit-options info field *and* the absence of any value in the subscribe email field. This is enough. The proper thing would be to separate the functions into two separate scripts (as i did for the subscriber roster, this morning), but that will take adding another wrapper, etc - maybe when john gets a chance to clean up the wrapper situation... (That's not a prod, john - really!-) By the way! With the recent changes, it's now possible for you guys to see who actually are the members of the mailman-cvs list (a private list), via the web. There really are only three of us - john, barry, and me. In case you were curious... Ken
-rwxr-xr-xcgi/subscribe5
1 files changed, 3 insertions, 2 deletions
diff --git a/cgi/subscribe b/cgi/subscribe
index 8dfb0b73a..dce685bc7 100755
--- a/cgi/subscribe
+++ b/cgi/subscribe
@@ -86,7 +86,8 @@ if form.has_key("SubscriberRoster"):
# Get the roster of subscribers.
call_script('mmroster', [list._internal_name])
-elif form.has_key("UserOptions"):
+elif (form.has_key("UserOptions")
+ or (form.has_key("info") and not form.has_key("email"))):
# Go to user options section.
if not form.has_key("info"):
doc.AddItem(htmlformat.Header(2, "Error"))
@@ -98,7 +99,7 @@ elif form.has_key("UserOptions"):
member = list.FindUser(addr)
if not list.FindUser(addr):
doc.AddItem(htmlformat.Header(2, "Error"))
- doc.AddItem(htmlformat.Bold("%s has not subscribed addr <i>%s</i>."
+ doc.AddItem(htmlformat.Bold("%s has no subscribed addr <i>%s</i>."
% (list.real_name, addr)))
doc.AddItem(list.GetMailmanFooter())
print doc.Format()