regular expression help w/ preg_split
Posted: Tue Jun 03, 2003 1:23 am
I am hopeless writing regular expressions..
Hopefully somebody might help me out..
I'm looking to do a preg_split and split by newline characters (any new line characters), but not newline characters that are quoted,
ie. split this: example \n rah rah
but not this: example "\n" rah rah
and if possible split by any new line characters, ie. \n or \r or ^M etc...
I'm trying to write it now, but as I said earlier, I'm hopeless with regex.
I got a few more regex questions, but hopefully this'll point me in the right direction
Marz.
Hopefully somebody might help me out..
I'm looking to do a preg_split and split by newline characters (any new line characters), but not newline characters that are quoted,
ie. split this: example \n rah rah
but not this: example "\n" rah rah
and if possible split by any new line characters, ie. \n or \r or ^M etc...
I'm trying to write it now, but as I said earlier, I'm hopeless with regex.
I got a few more regex questions, but hopefully this'll point me in the right direction
Marz.