Chevy Posted October 9, 2006 Share Posted October 9, 2006 Well I am making a friends system and I am stuck....[code]$fre = mysql_query("SELECT * FROM friends WHERE username_to='$player' || username_from='$player' && accepted='Yes'");[/code]and it doesn't work properly, any info? Link to comment https://forums.phpfreaks.com/topic/23434-mysql_query-problem/ Share on other sites More sharing options...
redarrow Posted October 9, 2006 Share Posted October 9, 2006 try this ok.[code]$fre = mysql_query("SELECT * FROM `friends` WHERE (`username_to`='$player') or (`username_from`='$player') and `accepted`='Yes'";[/code] Link to comment https://forums.phpfreaks.com/topic/23434-mysql_query-problem/#findComment-106283 Share on other sites More sharing options...
HuggieBear Posted October 9, 2006 Share Posted October 9, 2006 Use this:[code]$fre = mysql_query("SELECT * FROM friends WHERE (username_to = '$player' OR username_from = '$player') AND accepted='Yes'");[/code]RegardsHuggie Link to comment https://forums.phpfreaks.com/topic/23434-mysql_query-problem/#findComment-106284 Share on other sites More sharing options...
Chevy Posted October 9, 2006 Author Share Posted October 9, 2006 Thank you it work excellent now Link to comment https://forums.phpfreaks.com/topic/23434-mysql_query-problem/#findComment-106296 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.