Du kannst nicht mehr als 25 Themen auswählen Themen müssen mit entweder einem Buchstaben oder einer Ziffer beginnen. Sie können Bindestriche („-“) enthalten und bis zu 35 Zeichen lang sein.

text2html.inc 1.5KB

123456789101112131415161718192021222324252627282930313233
  1. <?php
  2. /**
  3. +-----------------------------------------------------------------------+
  4. | program/steps/utils/text2html.inc |
  5. | |
  6. | This file is part of the Roundcube Webmail client |
  7. | Copyright (C) 2005-2014, The Roundcube Dev Team |
  8. | |
  9. | Licensed under the GNU General Public License version 3 or |
  10. | any later version with exceptions for skins & plugins. |
  11. | See the README file for a full license statement. |
  12. | |
  13. | PURPOSE: |
  14. | Convert plain text to HTML |
  15. | |
  16. +-----------------------------------------------------------------------+
  17. | Author: Thomas Bruederli <roundcube@gmail.com> |
  18. +-----------------------------------------------------------------------+
  19. */
  20. $text = stream_get_contents(fopen('php://input', 'r'));
  21. // strip slashes if magic_quotes enabled
  22. if (get_magic_quotes_gpc() || get_magic_quotes_runtime()) {
  23. $html = stripslashes($html);
  24. }
  25. $converter = new rcube_text2html($text, false, array('wrap' => true));
  26. header('Content-Type: text/html; charset=' . RCUBE_CHARSET);
  27. print $converter->get_html();
  28. exit;