PDA

View Full Version : Trouble with Guestbook Script


heathabear
01-18-2003, 03:43 AM
Hi, I'm new
I'm trying to add a guestbook to my site, http://www.chapsticky.net.
I've been dealing with HTML for years, but this is my first attempt at CGI, so I was lucky to be able to get the script to work at all. The guestbook is located at http://www.chapsticky.net/gbook.html. The script seemed fully customizable, but when I go to post an entry, it posts in the ugliest colors. I've searched all through the script, and I can't figure out where to change this. Also, the entries load on the same page as the "sign guestbook" page. Is there anything I can do to change these aspects of the script? Alternatively, are there any other fully-customizable scripts that would be easy for someone very new to CGI to work with? I'll attach the script to this message in TXT form in case it will be of any help. Thank you so much for taking the time to read this, and have a lovely night!

MCookie
01-18-2003, 04:09 AM
Hi Heather,
look for this part in the script. Just change the color values in the bgcolor attributes...

$page_entry=<<__END_OF_PAGE_ENTRY__;
<table width=560 border=0 cellpadding=0 cellspacing=0 bgcolor="#CCE6FF">
<tr>
<td width=125>Name:</td>
<td width=435> $fields{'name'}</td> </tr>
<tr>
<td width=125 bgcolor="#FFFFCC">E-Mail:</td>
<td width=435 bgcolor="#FFFFCC"> $tzn</td> </tr>
<tr>
<td width=125 >Location:</td>
<td width=435> $fields{'location'}</td> </tr>
<tr>
<td width=125 bgcolor="#FFFFCC">Website:</td>
<td width=435 bgcolor="#FFFFCC"> <a href="$fields{'utl'}">$fields{'url'}</a></td> </tr>
<tr>
<td width=125 >Current Mood:</td>
<td width=435> $fields{'mood'}</td> </tr>
<tr>
<td width=125 >Current Music:</td>
<td width=435> $fields{'music'}</td> </tr>
<tr>
<td width=125 >Favorite Chapstick Flavor:</td>
<td width=435> $fields{'chapstick'}</td> </tr>
<tr>
<td width=125 >Date:</td>
<td width=435> $the_date</td> </tr>
<tr>
<td width=560 bgcolor="#FFFFFF" colspan=2><i>Comments</i><br>$fields{'message'}<hr></td> </tr>
</table>

And as for modifying the script - separate add entry page.. well, I think it's easier to install another one, like this one (separate entries and add entry page, smilies, admin), not too difficult, really..
http://www.webfresh.com/perl/fgb/index.shtml

heathabear
01-18-2003, 06:58 AM
Woah, thanks so much - don't know how I could have missed that. Ok, so I got that fixed, but it still looks like crap, imho. I took a look at that other script, but it looks really overwhelming, so I was thinking, at the bottom of the gbook.html thing, it says,

<!--NEVER EVER REMOVE THE bookmark line!!! This tells the script where
your reader entries begin -->
<!--bookmark-->

Now, if I put the bookmark thing into another HTML file, would I be able to some associate that with with the guestbook so that it made the page into a view entries page? Ah, and now there's an annoying "</html" at the bottom of the page, and I can't figure out where it's coming from. :/

Thank you so much for all of your help, I really appreciate it!