MySQL Forums
Forum List  »  PHP

Re: how to use PHP variable in MYSQL query?
Posted by: Peter Brawley
Date: January 22, 2008 09:05PM

Eh?

Try this:

$username = "White";
$qry = "SELECT * FROM tbl WHERE lastname = '$name'";
echo $qry;

What "doesn't work"?

PB
http://www.artfulsoftware.com

Options: ReplyQuote


Subject
Written By
Posted
Re: how to use PHP variable in MYSQL query?
January 22, 2008 09:05PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.