dcsimg
www.webdeveloper.com
Results 1 to 2 of 2

Thread: Live Feed

  1. #1
    Join Date
    Jul 2006
    Posts
    663

    Live Feed

    Hi, i want to add a live feed to the home page of my website, that captures the following activities for all people who use my site:

    - $username has just joined
    - $username has just updated their email address
    - $username has just changed their photo
    - etc...

    How should i go about capturing all of these? I have created a spreadsheet listing all of the activities that i want to capture... so should i just add an activity to a live-feed table in the database, each time one of these activites occure

    ========
    LIVE-FEED
    ========
    - id
    - timestamp
    - activity_desc


    Do you think this is the best way to set up / run the live feed, thanks in advance

  2. #2
    Join Date
    May 2003
    Posts
    599
    your strategy sounds resonable...You will also need to add a userID field to know which user performed the action.

    You could also expand on your activity table to get more granular:

    ACTIVITY:
    ID
    UserID
    TimeStamp
    Action
    Affected

    then values would be inserted: ('HamHock','0000-00-00 xx:xx:xx','update','profile_pic')

    The reason ID is different from UserID is incase you wanted to show multiple profile updates within a time frame, rather than just showing the last update from the user...this would allow you to say "HamHock updated their pic and email address..."
    Last edited by hastx; 10-02-2012 at 10:00 AM. Reason: added explanation

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles