alecpl
2011-06-27 68070e448c6c8cd09faa75fd70ff11bfea764cc1
commit | author | age
dd53e2 1 <?php
T 2 /*
677e1f 3
dd53e2 4  +-----------------------------------------------------------------------+
677e1f 5  | program/steps/utils/html2text.inc                                     |
dd53e2 6  |                                                                       |
e019f2 7  | This file is part of the Roundcube Webmail client                     |
f5e7b3 8  | Copyright (C) 2005-2010, The Roundcube Dev Team                       |
dd53e2 9  | Licensed under the GNU GPL                                            |
T 10  |                                                                       |
11  | PURPOSE:                                                              |
677e1f 12  |   Convert HTML message to plain text                                  |
dd53e2 13  |                                                                       |
T 14  +-----------------------------------------------------------------------+
677e1f 15  | Author: Thomas Bruederli <roundcube@gmail.com>                        |
dd53e2 16  +-----------------------------------------------------------------------+
T 17
18  $Id$
19
20 */
21
747289 22 $html = $HTTP_RAW_POST_DATA;
A 23
24 // Replace emoticon images with its text representation
25 $html = rcmail_replace_emoticons($html);
26
27 $converter = new html2text($html);
dd53e2 28
677e1f 29 header('Content-Type: text/plain; charset=UTF-8');
11bcac 30 print rtrim($converter->get_text());
dd53e2 31 exit;
T 32
b25dfd 33