mysql_real_escape_string making variable equal nothing


Posted on 16th Feb 2014 07:03 pm by admin

i post a form and i post the variable:
Code: $var = $_POST[variable];then i echo $var its what i submitted the variable to be.
then i add the mysql_real_escape_string() function to it
spell it correctly too
Code: $var = mysql_real_escape_string($_POST[variable]);then i echo the variable it equals nothing?
why?
is it because i havent added a mysql query on yet or what?

No comments posted yet

Your Answer:

Login to answer
316 Like 44 Dislike
Previous forums Next forums
Other forums

Gaining access to Drop Down Menu Variable
code is below, I am creating a drop down menu. I want to echo the value selected in the drop down me

Echo Tweaking help!
HI. I would like to have the output of the entered variables repeat forever, but it's stopping at th

noob cURL help
I have a pretty basic form that I need to cURL post to a file in my includes folder (includes/login.

Need help: how to catch acess of undefined class properties
Hello. I am learning OO with PHP and have hit a problem.
Some code runs as perfectly valid code,

change text color with a jQuery code
Hihow can I change the text in a asp:TextBox to a different color when I start typing using jQuery?I

Help If user voted, block them
On my Prayer request site, i let users Click a button to Pray for somone that has posted a pray, i g

does anyone know a php script to send mail using gmails/googles free smtp server
cause i heard u can do that but i dont know how

Help: calling function
Hi,
Is it possible to call a php function on page close?
If yes, could you explain how and whe

Collecting AOL Search Terms
I am attempting to collect AOL search terms. I know the code is correct (it works for google, bing,

mysql_real_escape_string
Let me preface this that I am very much a PHP noob, but I have some SQL training (not necessarily My

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash