Escaping Commas from a string
I am reading info from a databse for display in html. Issue i have is sometimes the info might have commas in its for example its may say something like:
Bob's New House
Bob's "New" House
When i display in the html its obviously causing issues. I am wondering what the neatest way to handle this is? Assume i can just preg replace " or ' with " but is this the best way to do it for all display in html? Are there other characters ought to cater for and are there any standard php functions to handle this scenario?
Have a look here..
That worked perfectly Simon. Cheers.
|All times are GMT. The time now is 02:19 PM.|
Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0