如何将换行符转换为代码?例如,
$array = array(
'title' => 'abc',
'content' => 'a paragraph
line break
line break
'
);
我想转换$array['content']
为
a paragraph\r\n\t\r\n\tline break\r\n\t\r\n\tline break\r\n\t\r\n\t
如何将换行符转换为代码?例如,
$array = array(
'title' => 'abc',
'content' => 'a paragraph
line break
line break
'
);
我想转换$array['content']
为
a paragraph\r\n\t\r\n\tline break\r\n\t\r\n\tline break\r\n\t\r\n\t