...

View Full Version : Strip \u000d\u000a ?



rfresh
09-02-2011, 06:51 PM
I'm translating a string from english to spanish. I'm using the MS Bing translator. When the translated text is returned, I write it to a file and when I open the file up in my editor I see these characters: "\u000d\u000a" between lines of text.

I know those are unicode chars but how do I convert them to regular \r\n chars?

The following code doesn't work:



$test=str_replace("u000d", "", $s);


Thanks...

sunfighter
09-02-2011, 08:08 PM
$test=str_replace("\u000d\u000a", "\r\n", $s);



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum