How i can get value from query?

I have this code

[php]$this_id = $_POST[‘id_request’];

$to = sprintf("SELECT email FROM members WHERE user_id = '$this_id'");

[/php]

I want to get the email address
but it return to me
SELECT email FROM members WHERE user_id = ‘11’

i got the solution here
http://php.net/manual/en/function.mysql-query.php

;D

If you payed attention, this is also on that page:

Warning

This extension is deprecated as of PHP 5.5.0, and will be removed in the future. Instead, the MySQLi or PDO_MySQL extension should be used. See also MySQL: choosing an API guide and related FAQ for more information. Alternatives to this function include:
mysqli_query()
PDO::query()</blockquote>
Sponsor our Newsletter | Privacy Policy | Terms of Service