It's been a long night and maybe I'm so tired I'm overlooking something simple, but this has me dumbfounded.
I know for a fact - 100% that these variables contain a value :
$receiver_id
$myid
$receiver_username
I defined them at the top of the page and echoed them and they all return their value, yet when I plug them into the query I get nothing (which normally would lead me to believe they don't contain a value or they are misspelled). If I use straight values in the query it works fine. I know beyond a shadow of a doubt that those variables all match up to a value in the table in proper column, no misspellings, etc.
What would make this query not work when I plug in the variables?
$nick="SELECT nick FROM address_book WHERE their_id='$receiver_id' AND my_id='$myid' AND their_username='$receiver_username'" or die(mysql_error());
$nresult=mysql_query($nick);
while($n=mysql_fetch_array($nresult)){
$nickn=$n['nick'];}