Hi,
I am not asking how topic subscription works here. I am asking how to make one. I have written a nice looking forum system and I would like to create topic subscription function also. I know couple of methods to do this but they sound too 'heavy'.
What do you suggest? How do these IPB's, PHPBB's and other forums' subscription work?
Thank you for your time,
Kai
Topic Subscription question
Moderator: General Moderators
- kaisellgren
- DevNet Resident
- Posts: 1675
- Joined: Sat Jan 07, 2006 5:52 am
- Location: Lahti, Finland.
simple, make a table called
users_subscriptions
with the following fields:
user_id, topic_id
when someone posts in a topic:
SELECT user_id FROM users_subscriptions WHERE topic_id=$thistopic
Loop thru the result, and mail() everyone
Oh and, when someone subscribes to a topic, just insert a row with the topic id and his id in that table ;p
users_subscriptions
with the following fields:
user_id, topic_id
when someone posts in a topic:
SELECT user_id FROM users_subscriptions WHERE topic_id=$thistopic
Loop thru the result, and mail() everyone
Oh and, when someone subscribes to a topic, just insert a row with the topic id and his id in that table ;p