Jump to content

social network site ( mini feeds ) ?!


hassank1

Recommended Posts

Hey

I am working on a social network site (friends - groups etc..) . so I want to create mini-feeds so every users get some information about his friends , groups he joined etc..

 

example when he sign in he get something like :

 

X send friend request to Y.

X joined group G1.

Z and Y are now friends

Z wrote in the group G1 ..

X updated his profile

etc..

 

my tables are (groups - friends - users - requests (for friend requests) .. etc...)

 

so I want to know how should I design this concept .. (ex:creating one table in the db ? many tables ?) what should I put in these tables (fields ) .. is there a good programming practice I must follow ...

 

and if you know something else that might help please let me know

 

thanks.

 

 

Link to comment
https://forums.phpfreaks.com/topic/86199-social-network-site-mini-feeds/
Share on other sites

  • 4 months later...

Sorry about the incredibly late reply. I've done something similar to a forum some time ago.

 

What I did was that I set up a separate table for the feed. It contains these fields

 

- User id (to join in with the user table)

- Feed id (smallint, for unique identification. key, auto-increment)

- Feed story (for the basic text, plus links etc)

- Where the feed was generated (was it from the gallery? the download center? great for stats)

- Visibility (in my system, people can chose to be invisible in the feeds, but admins can always see the activity)

- Timestamp (so that you have a period to pick from later)

 

I prune the table sometimes though, it grows big quite soon ;)

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.