richcleverley
MIS
Hi,
I am developing a site which as part of it stores user text input in a mysql database. This data is place names and various ones have an apostrophe in them. This data is used to dynamically populate drop down boxes and if a place has an apostrphe in it it causes the dropdown to stop working.
Is there a way to escape (\) the apostrophe before it is written to the database so the drop downs work properly?
eg, user input's Cap D'agde in the town field, I want Cap D\'agde to be written to the database.
Thanks,
Richard
I am developing a site which as part of it stores user text input in a mysql database. This data is place names and various ones have an apostrophe in them. This data is used to dynamically populate drop down boxes and if a place has an apostrphe in it it causes the dropdown to stop working.
Is there a way to escape (\) the apostrophe before it is written to the database so the drop downs work properly?
eg, user input's Cap D'agde in the town field, I want Cap D\'agde to be written to the database.
Thanks,
Richard