0

I have a website where users can add their friends. What I am trying to achieve is to show every user that who are their friends that are currently online. If any one knows a link to any script or tutorial that explains this, Please help.

3
Contributors
3
Replies
6
Views
6 Years
Discussion Span
Last Post by nats01282
0

Hi

you have to create a table in sql friends for every user. in this table store detail of their Friends. And when user login to website check his id or username in these friends table if data found display the name to users

0

code to set a user online
what you could do which im am gonna do is check the users are friends then on every link that user clicks it update's the (lets say) Time table with there id and the time + X mins.

now with the other friend looking to see who is online
check the time table for friends and check the friends to see if the current time is less then time + X mins if so we know that friend is online

0

code to set a user online
what you could do which im am gonna do is check the users are friends then on every link that user clicks it update's the (lets say) Time table with there id and the time + X mins.

now with the other friend looking to see who is online
check the time table for friends and check the friends to see if the current time is less then time + X mins if so we know that friend is online

you could also try creating a php/mysql chat with this i have done it once and it worked fair well

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.