Hi there,
Just a quick q:
Is there a way to escape a comma- possibly with a fancy regex or something?
Cheers
A way to escape a comma?
Moderator: General Moderators
A little bit of background-info:
I wrote a little app using Magpie to parse a RSS/XML file into an array.
One field of that array is getting filled with 'taxonomy terms'. Sometime those terms are containing comma's (E.g. "Folksonomy, multiple Taxonomies combined"). Alas my app doesn't like that programmatically wise, because I am using a function to comma-separate terms
This unfortunately will render the term in question into the two new terms: "Folksonomy" and "multiple Taxonomies combined".
Cheers.
I wrote a little app using Magpie to parse a RSS/XML file into an array.
One field of that array is getting filled with 'taxonomy terms'. Sometime those terms are containing comma's (E.g. "Folksonomy, multiple Taxonomies combined"). Alas my app doesn't like that programmatically wise, because I am using a function to comma-separate terms
This unfortunately will render the term in question into the two new terms: "Folksonomy" and "multiple Taxonomies combined".
Cheers.
- John Cartwright
- Site Admin
- Posts: 11470
- Joined: Tue Dec 23, 2003 2:10 am
- Location: Toronto
- Contact:
Normally when the character used as a delimeter is found within the string, the string is wrapped in quotes.
Check out the user comments on how to parse csv strings
Check out the user comments on how to parse csv strings
- Josh1billion
- Forum Contributor
- Posts: 316
- Joined: Tue Sep 11, 2007 3:25 pm
- Kieran Huggins
- DevNet Master
- Posts: 3635
- Joined: Wed Dec 06, 2006 4:14 pm
- Location: Toronto, Canada
- Contact:
- Josh1billion
- Forum Contributor
- Posts: 316
- Joined: Tue Sep 11, 2007 3:25 pm