Floydian Posted May 7, 2008 Share Posted May 7, 2008 Does anyone know where I might find some information on designing forum code? Specifically, the problem I'm having is in keeping track of read and unread threads. If I make a log table, that notes every thread a person goes to, then the number of rows required in that log that would be needed to have every thread marked for every user would blow up exponentially as time went on. I've tried to come up with some sort of compromise where I log things based on a date. If the forum is marked read, update the date in the users table. But then, if someone posts a post, and another person posts a post in a different thread. You can't just update that date in the users table when they've read one of the posts. So I'm thinking a combination of a date in the users table as a sort of a marker of how far back to go for "unread" threads, and then a log for threads read after that marker is set. I still haven't gotten it working though. If someone knows of something somewhere that I can read and learn about this, it'd be greatly appreciated. Or if you've done this sort of thing, and are kind enough to give me some pointers, that'd be great as well. Quote Link to comment Share on other sites More sharing options...
Guest Anonymous Posted May 7, 2008 Share Posted May 7, 2008 Re: Forum Design I used a simple one .... UNREAD TEXT NOT NULL DEFAULT ""; Now, insert into that a CSV list of the last topics in each forum read by the player: 1,100,400,200,400 Adding a forum - adds to the end of the list Deleting a forum is a little more complex but can be done Use the FIND_IN_SET function in MySQL... If you need, I have the ADD_TO_SET, and REMOVE_FROM_SET functions that MySQL "forgot". It works... kinda... might need some thinking about Quote Link to comment Share on other sites More sharing options...
Floydian Posted May 8, 2008 Author Share Posted May 8, 2008 Re: Forum Design Sweet :D At this point, my main concern is the announcements forum. I'll do some experimenting and see what happens. Thanks for the suggestion Nyna ;) Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.