4 +-----------------------------------------------------------------------+
5 | program/steps/utils/html2text.inc |
7 | This file is part of the Roundcube Webmail client |
8 | Copyright (C) 2005-2010, The Roundcube Dev Team |
9 | Licensed under the GNU GPL |
12 | Convert HTML message to plain text |
14 +-----------------------------------------------------------------------+
15 | Author: Thomas Bruederli <roundcube@gmail.com> |
16 +-----------------------------------------------------------------------+
18 $Id: html2text.inc 4410 2011-01-12 18:25:02Z thomasb $
22 $html = $HTTP_RAW_POST_DATA;
24 // Replace emoticon images with its text representation
25 $html = rcmail_replace_emoticons($html);
27 $converter = new html2text($html);
29 header('Content-Type: text/plain; charset=UTF-8');
30 print rtrim($converter->get_text());