Something .. YEAHHH!! thanks it works! 😛 one last thing, I wish you could see your username by clicking the profile, but me you're not logged in or your session has expired😕 is sid 🙂
Chatter of the day
Started on the old forum in September 2009 · view the original in the archive · old links redirect here
TL;DR · summary of 27 replies
- $sql=mysql_fetch_array(mysql_query(""SELECT uid, avatar FROM ibwf_users ORDER BY RAND() LIMIT 1"")); should be used to fetch user profile photos.
- The extra sql for changing the photo every 24 hours needs to be added in ibwf_settings with name= pod and value = 1.
- $sid = $_GET["sid"]; should be placed above the code that uses sid for session handling.
Written automatically from the replies by a language model on our own server. It can be wrong; the posts below are the source.
for some reason $sid in being canceled out or not collecting properly try putting $sid = $_GET["sid"]; above the code 🙂
i cant see anything wrong with the code iv posted 🙂 so im guessing its a problem on the page your putting it on 🙂
sql
INSERT INTO `ibwf_settings` ( `id` , `name` , `value` )
VALUES (
NULL , 'doc', '1'
);
script:
$check = mysql_fetch_array(mysql_query("SELECT value FROM ibwf_settings WHERE name='doc'"));
$date = "".date("d")."";
if($check[0]!=$date){
$user = mysql_fetch_array(mysql_query("SELECT id FROM ibwf_users ORDER BY RAND() LIMIT 1"));
mysql_query("UPDATE ibwf_settings SET value='".$date."' WHERE name='doc'");
mysql_query("UPDATE ibwf_settings SET value='".$user[0]."' WHERE name='pod'");
}
I removed the code, and replace all the code with the copy paste, modify SQL, but do not see anything😐