Page 3 of 3 FirstFirst 123
Results 21 to 26 of 26

Thread: Php Messaging System

  1. #21
    Join Date
    Mar 2003
    Posts
    492
    Rep Power
    0

    Default

    Yes, let's continue the mission of helping you. So Wallizzle I have imagined you have grasped the use of your intermediary table, now to the messaging portion of it, have you decided how you wish to tackle that? By the way, what backend are you planning on using, MySQL?

  2. #22
    Join Date
    Mar 2005
    Posts
    161
    Rep Power
    0

    Default

    Mysql db... I was thinkn i was plannin on storing those in a table (lets call it Mail_table). which i would have auto_int [id], user_id, sender_id, and then the message recieved(data type blob i guess), then make another column that says reviewed... so I can tell if it has already been read, which probably would hold value true/false, btw does mysql allow boolean values?
    Owned:
    >> Samsung Galaxy Note 3; LG Optimus G; Nexus 4; Samsung Galaxy Ace Duos
    << Microsoft Surface RT; Dell Venue 8; Asus Transformer

  3. #23
    Join Date
    Mar 2003
    Posts
    492
    Rep Power
    0

    Default

    You should try and separate messages in their own table for broadcasting. you can just enter one message and then attach that way you can enter in your like delivered messages table, many entrants pointing to one message. So try and abstract that message from your user.

    Ideally a message should not know about a user. A message is just words. The delivery information should be handled by a 'broker' of sorts. Your broker will then based on information from the sender give the recipient a message id and say, 'here get this message from the server and read it.' When you have that level of abstraction, you can say to a hundred users, 'here is a message id, go and read it' without duplicating the message itself for all users.

    Hope I am making myself clear.
    Last edited by Blunty Killer; Aug 10, 2007 at 05:36 PM.

  4. #24
    Join Date
    Mar 2005
    Posts
    161
    Rep Power
    0

    Default

    Dang the thought itself is kinda abstract rude boy... so wat u sayin dont insert a user_id in the message table, however i should let the point the user to the message Id.... now i would have to create another table to link the user_id to the message... is that what your saying?
    Owned:
    >> Samsung Galaxy Note 3; LG Optimus G; Nexus 4; Samsung Galaxy Ace Duos
    << Microsoft Surface RT; Dell Venue 8; Asus Transformer

  5. #25
    Join Date
    Mar 2003
    Posts
    492
    Rep Power
    0

    Default

    Yes it will save you alot of headache. Just have one table with delivery information. This table should have a sender, recipient, message_id, date_delivered, etc. All information necessary to know about the delivery of a message. You then attach the message id to each delivery entry. This way you can broadcast your messages. So you could make 4 entries from user A with recipients B,C,D,E and have all entries point to message id 15. That way you do not have to put the message beside each recipient. You just use one message for all intended recipients.

  6. #26
    Join Date
    Mar 2005
    Posts
    161
    Rep Power
    0

    Default

    well i neva thought about it that way.... man how long have you been doin this kinda thing... like forever huh? ur the greatest.... nuff blessings

    I'll be sure to link u wit anything other issues i run into. wat other languages u know?
    Owned:
    >> Samsung Galaxy Note 3; LG Optimus G; Nexus 4; Samsung Galaxy Ace Duos
    << Microsoft Surface RT; Dell Venue 8; Asus Transformer

Posting Permissions

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