Конвертировать символы BackSlash PHP
$text = str_replace(array('\t','\n','\r','\f','\b','\a','\e','\\\\'),
array("\t","\n","\r","\f","\010","\007","\033","\\"), $text);
Hungry Heron