I have a MySQL table called blocks with the following fields:
blockid
blockerloginid
blockeeprofile
blockon
time
I would like to show http://www.url1.com if there is a row in the table that exists where blockerloginid = '$uid' and AND blockeeprofile = '$profile'
If there is not such a row, I would like to show http://www.url2.com.
How can I do this?
Easy enough SQL statement should sort it for ya
That should look for any rows in the table that have the uid and profile you specified. Assuming there should only be one with both of those values, it will check to see if the number of rows found was 1 or 0 and display the different links accordingly