SitePoint Sponsor |
|
User Tag List
Results 1 to 5 of 5
-
Dec 24, 2005, 04:22 #1
linking friends (was "serious question...")
As i stated earlier i m planning to make a simple hi5 using the help of Sitepoint forums... Work is going on and the problems occurs in below
> i had made a table `frensNetwork` which has `user_id`,`fren_id`
fields.....
suppose i had following entered fields
/user_id/ fren_id
1 / 2
1 / 5
1 / 3
2 / 5
2 / 8
5 / 22
(Note: 1 / 2 are values entered in user_id and fren_id fields respectively)
Suppose i m the user having user_id `1` . if i opens my profile and clicks on the 2,5,7 user_id's photo then it should show the status You<->2 OR 5 OR 7
as seen in HI5. But if i go to 2's profile and clik on user_id 8 then it should disply in the status as You<->2<->8.
(i hope u got my problems)
if the networks go huge then we have to generalizse the status...This is the think i want............
Can anybody provide the algorithm or Idea of linking friends as You<->xxx<->YYY
Note: Credit will be given for the help as will be dispalyed as "FrensNetwork Idea BY:[ ]" in the about us section
Thank U for reading
-
Dec 24, 2005, 20:14 #2
- Join Date
- Feb 2004
- Location
- Tampa, FL (US)
- Posts
- 9,854
- Mentioned
- 1 Post(s)
- Tagged
- 0 Thread(s)
i think i get what you're saying. if i log in to your site and i click on my friend rudy, then click on rudy's friend matthew, i should see a chart show that i clicked on rudy, then on matthew. right?
this is not a task that mysql will complete for you. what you need to do is store each name as you click on them in your host language's session data storage.
-
Dec 25, 2005, 04:10 #3
Thanks for the reply....
But there seems a problems using the SESSION
Suppose if the user opens the 2's id , 3's id , 8's id in new window then retrieving from the SESSION will cause to display the follwing results
You<->2<->3,<->8...which is quite undesired........
Can u please explaing more briefly using sessions to solve above problems
-
Dec 25, 2005, 22:02 #4
- Join Date
- Feb 2004
- Location
- Tampa, FL (US)
- Posts
- 9,854
- Mentioned
- 1 Post(s)
- Tagged
- 0 Thread(s)
i don't have a good answer for that. what is your host language? you will probably have better luck getting a good answer from that forum as it's usually the host language that deals with these types of issues, not mysql.
-
Dec 26, 2005, 01:18 #5
Thanks again for the reply
i am using php with mysql
Thank u
Bookmarks