Chatter of the day

Started on the old forum in September 2009 · view the original in the archive · old links redirect here

27 replies · 1,237 views · started 17 years ago · 1 min read

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.

3 participants
Leviathan73 Senior · 260 posts #21

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 🙂

something else Fellow · 2,296 posts #22

Does your site use sid ? or does it use ses ? or something else? 🙂

something else Fellow · 2,296 posts #23

for some reason $sid in being canceled out or not collecting properly try putting $sid = $_GET["sid"]; above the code 🙂

Leviathan73 Senior · 260 posts #24

put on the code that you gave me, but you can not see profile

something else Fellow · 2,296 posts #25

i cant see anything wrong with the code iv posted 🙂 so im guessing its a problem on the page your putting it on 🙂

Leviathan73 Senior · 260 posts #26

help some, the picture has not changed at midnight, is the same as yesterday😳

something else Fellow · 2,296 posts #27

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'");
}
Leviathan73 Senior · 260 posts #28

I removed the code, and replace all the code with the copy paste, modify SQL, but do not see anything😐

Write your reply now; next you create a free account (or sign in) and it is posted right away. Sign in to reply.

Similar topics

Keyboard shortcuts

g f
Go to forums
g h
Go to your feed
g m
Go to messages
r
Reply (in a topic)
/
Search
j
Next post
k
Previous post
?
This list
Ctrl/⌘ + Enter
Send what you are writing
Ctrl/⌘ + B / I
Bold / italic while writing
Esc
Close