View Full Version : Comment forms?


myoshida
05-05-2006, 01:26 AM
I have no idea if I'm posting this in the right place, but I don't think it pertains to java, css, or basic html, so I thought it might be something advanced.

I'm looking for a means to post pictures on my website, and have a form on the page that will enable visitors to leave comments about the pictures. I know there are several gallery programs like this out there, but I've not had any luck with the ones I've tried. Can anyone tell me what it is I need to look for, or even better, tell me what sort of code I need? Whenever I've tried searching script sites, I can find guestbook scripts and e-mail forms, but nothing like a comment field that will show up on the page after being submitted.

Any help is greatly appreciated!

Phillip
05-05-2006, 12:09 PM
Hello, well basicly you'd need a folder (in FTP) which allows users to upload
pictures so set it as all priverliges, then using a simple query
$query = "INSERT into PICTURES WHERE url='$url'"; << i think

then create a database.

CREATE TABLE pictures
picture_id INT unsigned not null
picture_url VARCHAR not null
discription TEXT not NULL
comment TEXT not null
date_entered DATTIME NOT NULL
BY VARCHAR NOT NULL

then for your mysql_fetch_array this is what would return the values. Obv
i haven't added the full script I could make u the full script or someone else
if you don't understand it.

while ($row = mysql_fetch_array($result)
echo '<IMG src='$row[2]' width='80' height='90' border='0' alt='$row[3]' /> <Br /><br /> <b>Comments</b> echo '$row[4]';

something like that anyway. I don't know if that's right - I could make the script better PM me and I will work on it!