I have a string "First line | second line | third line"
How can I replace | with a new line character?
I'm trying to use preg_replace but with no liuck
I have a string "First line | second line | third line"
How can I replace | with a new line character?
I'm trying to use preg_replace but with no liuck
There is more generic case where e.g. '' serves as replacwment string:
// Provides: Hll Wrld f PHP
$vowels = ["a", "e", "i", "o", "u", "A", "E", "I", "O", "U"];
$onlyconsonants = str_replace($vowels, "", "Hello World of PHP");