[ad_1]
You can use:
$strPar = "12345|12345|12345|12345
12345|12345|12345|12345
12345|12345|12345|12345";
$strpar = str_replace("\n", "|", $strPar);
Make sure the \n character is in double quotes
2
[ad_2]
solved Replace ‘New Line’ with ‘|’ [closed]