X-Git-Url: https://code.citadel.org/?a=blobdiff_plain;f=webcit%2Fhtml2html.c;h=3b6a9c3e83ad57fb7419d01a42572d20c3b22ace;hb=01008640a5b0d110e76db7e885accf45abfd20d9;hp=023ab7c4af8184dfc9193003d28079a8d3964f38;hpb=3393a0510a990ef61044a1f3dbd97950e5532f33;p=citadel.git
diff --git a/webcit/html2html.c b/webcit/html2html.c
index 023ab7c4a..3b6a9c3e8 100644
--- a/webcit/html2html.c
+++ b/webcit/html2html.c
@@ -44,6 +44,7 @@ void output_html(void) {
int output_length = 0;
char new_window[SIZ];
int brak = 0;
+ int in_link = 0;
int i;
int linklen;
@@ -111,8 +112,23 @@ void output_html(void) {
strcpy(converted_msg, "");
ptr = msgstart;
while (ptr < msgend) {
+ /* Change mailto: links to WebCit mail, by replacing the
+ * link with one that points back to our mail room. Due to
+ * the way we parse URL's, it'll even handle mailto: links
+ * that have "?subject=" in them.
+ */
+ if (!strncasecmp(ptr, "...
+ * tags, so we don't turn things that look like URL's into
+ * links, when they're already links.
+ */
+ if (!strncasecmp(ptr, "') --brak;
converted_msg[output_length] = *ptr++;