summaryrefslogtreecommitdiff
path: root/roundcubemail/index.php
diff options
context:
space:
mode:
authorestadtherr <estadtherr@208e9e7b-5314-0410-a742-e7e81cd9613c>2006-09-14 03:49:28 +0000
committerestadtherr <estadtherr@208e9e7b-5314-0410-a742-e7e81cd9613c>2006-09-14 03:49:28 +0000
commita4332663cfcdb53b352c8646f78855ae3436cfec (patch)
treeceaf2d8afbf791e9d007cfe7a676fc1e0790b7a6 /roundcubemail/index.php
parent8b3252550799d1b69ba8ff0c0fb3f916608c2e1d (diff)
Initial TinyMCE editor support (still need to work on spellcheck and skins)
git-svn-id: https://svn.roundcube.net/trunk@344 208e9e7b-5314-0410-a742-e7e81cd9613c
Diffstat (limited to 'roundcubemail/index.php')
-rw-r--r--roundcubemail/index.php17
1 files changed, 16 insertions, 1 deletions
diff --git a/roundcubemail/index.php b/roundcubemail/index.php
index 85a9eefef..4e9dee1c7 100644
--- a/roundcubemail/index.php
+++ b/roundcubemail/index.php
@@ -81,6 +81,7 @@ require_once('include/rcube_imap.inc');
require_once('include/bugs.inc');
require_once('include/main.inc');
require_once('include/cache.inc');
+require_once('lib/html2text.inc');
require_once('PEAR.php');
@@ -145,6 +146,21 @@ if ($_action=='error' && !empty($_GET['_code']))
raise_error(array('code' => hexdec($_GET['_code'])), FALSE, TRUE);
}
+// handle HTML->text conversion
+if ($_action=='html2text')
+ {
+ $htmlText = $HTTP_RAW_POST_DATA;
+ $converter = new html2text($htmlText);
+
+ // TODO possibly replace with rcube_remote_response()
+ send_nocacheing_headers();
+ header('Content-Type: text/plain');
+ $plaintext = $converter->get_text();
+ print $plaintext;
+
+ exit;
+ }
+
// try to log in
if ($_action=='login' && $_task=='mail')
@@ -241,7 +257,6 @@ if ($_action=='keep-alive')
exit;
}
-
// include task specific files
if ($_task=='mail')
{