This is what I am trying to do:
$str is something like "Hello, this is a string with white space in it.|Second half with white space." How can I get both $part1 and $part2 to include all the spaces?PHP Code:sscanf($str, "%s|%s", $part1, $part2);
Printable View
This is what I am trying to do:
$str is something like "Hello, this is a string with white space in it.|Second half with white space." How can I get both $part1 and $part2 to include all the spaces?PHP Code:sscanf($str, "%s|%s", $part1, $part2);
you have to have a %s for each and every word if you do it that way.