9 #include <sys/socket.h>
12 #include <netinet/in.h>
25 * List subscription handling
37 strcpy(WC->wc_username, "");
38 strcpy(WC->wc_password, "");
39 strcpy(WC->wc_roomname, "");
41 wprintf("<HTML><HEAD><TITLE>List subscription</TITLE></HEAD><BODY>\n");
43 strcpy(cmd, bstr("cmd"));
44 strcpy(room, bstr("room"));
45 strcpy(token, bstr("token"));
46 strcpy(email, bstr("email"));
47 strcpy(subtype, bstr("subtype"));
50 "<TABLE WIDTH=100%% BORDER=0 BGCOLOR=000077><TR><TD>"
51 "<FONT SIZE=+1 COLOR=\"FFFFFF\""
52 "<B>List subscribe/unsubscribe</B>\n"
53 "</TD></TR></TABLE><BR>\n"
59 if (!strcasecmp(cmd, "subscribe")) {
60 serv_printf("SUBS subscribe|%s|%s|digest|%s/listsub",
67 wprintf("<CENTER><H1>Confirmation request sent</H1>"
68 "You are subscribing <TT>");
70 wprintf("</TT> to the "");
72 wprintf("" mailing list. The listserver has "
73 "sent you an e-mail with one additional "
74 "Web link for you to click on to confirm "
75 "your subscription. This extra step is for "
76 "your protection, as it prevents others from "
77 "being able to subscribe you to lists.<BR><BR>"
78 "Please click on the link which is being "
79 "e-mailed to you and your subscription will "
80 "be confirmed.<BR></CENTER>\n"
84 wprintf("<FONT SIZE=+1><B>ERROR: %s</B>"
92 * Any other (invalid) command causes the form to be displayed
95 FORM: wprintf("<FORM METHOD=\"POST\" ACTION=\"/listsub\">\n"
99 wprintf("<TR><TD>Name of list</TD><TD>"
100 "<INPUT TYPE=\"text\" NAME=\"room\" "
104 wprintf("\" MAXLENGTH=128></TD></TR>\n");
106 wprintf("<TR><TD>Your e-mail address</TD><TD>"
107 "<INPUT TYPE=\"text\" NAME=\"email\" "
111 wprintf("\" MAXLENGTH=128></TD></TR>\n");
114 "<INPUT TYPE=\"submit\" NAME=\"cmd\""
115 " VALUE=\"subscribe\">\n"
116 "<INPUT TYPE=\"submit\" NAME=\"cmd\""
117 " VALUE=\"unsubscribe\">\n"
121 wprintf("<BR>When you attempt to subscribe or unsubscribe to "
122 "a mailing list, you will receive an e-mail containing"
123 " one additional web link to click on for final "
124 "confirmation. This extra step is for your "
125 "protection, as it prevents others from being able to "
126 "subscribe or unsubscribe you to lists.<BR>\n"
132 * Since this isn't part of a normal Citadel session, we bail right
133 * out without maintaining any state.
135 /* wDumpContent(2); */
136 wprintf("</BODY></HTML>\n");
137 end_webcit_session();