With PHP of course, using our trusty old MySQL database to back it. Don't be scared off though, this is not as complicated as you may think it to be. This tutorial will outline the steps to create such a discussion board, teaching you a number of things on the way. Yes, I know, Phorum (http://www.phorum.org/) is a free discussion board, also made with PHP and using SQL databases. The thing is, how can I teach you a few things by just forwarding you to a different site? Exactly.
We should start our tutorial with a checklist of things we need, so you don't get stuck half-way through the tutorial not knowing what is going on, or why something isn't working.
CREATE TABLE posts (
ID int(5) DEFAULT '0' NOT NULL auto_increment,
TopicID int(5) DEFAULT '0' NOT NULL,
Name varchar(50) NOT NULL,
Email varchar(50) NOT NULL,
Password varchar(50) NOT NULL,
TimeStamp varchar(10) NOT NULL,
Post text NOT NULL,
PRIMARY KEY (ID)
);
CREATE TABLE topics (
ID int(5) DEFAULT '0' NOT NULL auto_increment,
TopicName varchar(50) NOT NULL,
PRIMARY KEY (ID)
);
Why two? We will be making an index page, listing all of the available topics to comment on. The other part, messages, will hold all the info on actual posts by the users. The fields will kind of explain themselves as I go, so lets move on.