X-Git-Url: https://vcs.fsf.org/?p=squirrelmail.git;a=blobdiff_plain;f=functions%2Fmailbox.php;fp=functions%2Fmailbox.php;h=bb281879ab2f75af62657e237546dd5160e588f7;hp=38fe457e9a92a73c0fbdb51ef040042da22f8092;hb=4809f4894f2e81992b5e172aacb3e337da29e615;hpb=6b96544adcccc142809cde809395d31fc1ae4b93 diff --git a/functions/mailbox.php b/functions/mailbox.php index 38fe457e..bb281879 100644 --- a/functions/mailbox.php +++ b/functions/mailbox.php @@ -245,7 +245,6 @@ $message["INFO"]["MAILBOX"] = $mailbox; $message["HEADER"] = fetchHeader($imapConnection, $id); $message["ENTITIES"] = fetchBody($imapConnection, $message["HEADER"]["BOUNDARY"], $id, $message["HEADER"]["TYPE0"], $message["HEADER"]["TYPE1"]); - return $message; } @@ -526,7 +525,14 @@ $read = $entity; } + function parseHTMLMessage($line) { + /** Add any parsing you want to in here **/ + return $line; + } + function parsePlainTextMessage($line) { + /** Add any parsing you want to in here */ + $line = "^^$line"; if ((strpos(strtolower($line), "> or > are found at the beginning of a line, I'll assume that was - replied text, so make it different colors **/ if (strpos(trim(str_replace(" ", "", $line)), ">>") == 2) { $line = substr($line, 2, strlen($line)); $line = "$line
\n"; @@ -557,8 +561,6 @@ $line = "$line
\n"; } - /** This translates "http://" into a link. It could be made better to accept - "www" and "mailto" also. That should probably be added later. **/ if (strpos(strtolower($line), "http://") != false) { $line = ereg_replace("
", "", $line); $start = strpos(strtolower($line), "http://");