improve the code that removes \r characters

This commit is contained in:
Emanuil 2013-08-31 19:54:14 +03:00
parent 609ad47c38
commit 4a6bb88239
1 changed files with 2 additions and 1 deletions

View File

@ -50,7 +50,8 @@ class Parsedown
$text = preg_replace('{^\xEF\xBB\xBF|\x1A}', '', $text);
# Removes \r characters.
$text = str_replace("\r", '', $text);
$text = str_replace("\r\n", "\n", $text);
$text = str_replace("\r", "\n", $text);
# Replaces tabs with spaces.
$text = str_replace("\t", ' ', $text);