Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
09-09-2009, 06:11 AM #1
- Join Date
- Mar 2006
- Thanked 0 Times in 0 Posts
Simple Comment Script for Gallery type webpage?
I have a website where i host my webcomics. Each week i add a new comic and i use php/msql to display and go to the previous and next comics
What i would like to do is add a div under the area of my comic and have a simple comment script there, so that someone can comment on the comic, go to the next comic and leave different comments for that one. Before i just had a basic chat box.
Can someone help me out with a very simple comment system? Just name, email, website, comment. I'd like to be able to style the look of the comment system with css.
Thanks in advance,
Last edited by luminatingsky; 09-09-2009 at 06:18 AM.
09-09-2009, 06:51 AM #2
- Join Date
- Oct 2007
- Thanked 79 Times in 79 Posts
Create a new table in mysql, with the structure like
Then just use MySql insert codes, then to retrieve them, loop them through a mysql_fetch_assoc to display em.Code:CREATE TABLE IF NOT EXISTS `comments` ( `comment_id` MEDIUMINT NOT NULL AUTO_INCREMENT PRIMARY KEY, `name` VARCHAR(60) NOT NULL, `email` VARCHAR(60) NOT NULL, `body` TEXT NOT NULL )
Make an attempt and post back with what you've got.
$aString = is_string((string)array()) ? true : false; // true :D