Highlighted

escaping single quotes of query...

nif-S0eiaB

15-05-2008

hi there,



i am working on my first flex 3 php project and have come up
against a bit of a bump.

i have a php file which basically takes a string parameter
from flex which is the sql statement i want to run, it runs it and
returns the data.



my problem arises whenever i use single quotes in a query
e.g. select CONCAT(firstname,' ',lastname) as name from users

if i pass this in i get this error:

Error #1088: The markup in the document following the root
element must be well-formed.



i have tested and found this happens whenever i try passing
single quotes as part of any parameter to the php page.



i have also tried to escape the ways i know how (\' or ''),
but this isn't working and i can't seem to find any info on how to
do this.



does anyone know how i can go about doing this?



thanks a mil',

nikki

Replies

Highlighted

nif-S0eiaB

15-05-2008

hi atta,



thanks for the quick reply. it makes absolute sense, but
unfortunately, doesn't seem to work.

do you think there is some specific format that i need to
encode this stuff to when passing params with HTTPService
object?