954,568 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Want to pass a string through URL...

I want to pass this string $string="reg_personal.personal_sex='Female' OR reg_personal.marital_status='Single'"; through the URL...

Is it possible...I am not getting that... if the single quote is eliminated then there is no probs..
but i need that string in the exact way.... Is there any splitting and joining methods are available.

Please help me....

Thanks in adance,,
jino..

jino
Junior Poster
117 posts since Feb 2008
Reputation Points: 10
Solved Threads: 10
 

what for u want pass string with url...
its not secure

forzadraco
Junior Poster in Training
70 posts since Mar 2008
Reputation Points: 10
Solved Threads: 1
 

I agree with forzadraco: don't do this.
An attacker could simply call your page with:
page.php?string=;DELETE * FROM yourtable
and you're dead.

However, to answer your question, the function you're looking for is urlencode().

petr.pavel
Junior Poster
117 posts since Mar 2008
Reputation Points: 30
Solved Threads: 16
 

yeah forza petr.pavel

forzadraco
Junior Poster in Training
70 posts since Mar 2008
Reputation Points: 10
Solved Threads: 1
 

Thank u very much both of u...

jino
Junior Poster
117 posts since Feb 2008
Reputation Points: 10
Solved Threads: 10
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You