Thehotfix.net Logo                              To the forums          

How to Create Wordpress Guestbook Reloaded.

I’ve gotten emails from people griping that my previous post about making a guestbook for their Wordpress blogs does not work for them. I’m making up for that lame post right now!

Ok, I am writing this post under the assumption that:

1. The very first thing to do is open up your theme folder saved in your computer. Look for the file named “single.php”.

single-php-select

2. Copy (Ctrl-C) the file and Paste it (Ctrl-V). The file will automatically be named “Copy of single.php”. Rename the file to “guestbook.php”.

change-file-name

3. Open up guestbook.php in your favorite text editor (e.g. Notepad, UltraEdit).

On top of the file, right before:


<?php get_header(); ?>

Add:


<?php
/*
Template Name: Guestbook
*/
?>

Update: the code above should read “<?php”. For some reason Wordpress adds an extra space in my posts. Ugh.

Save the file (Ctrl-S). What we just did is create a separate template for your guestbook, which we will use when we create the new page.

4. Open up your FTP program. Change directory to your current theme folder.

Ex. blogdomain.com/wp-content/themes/theme_name/

5. Upload guestbook.php.

6. Access your Wordress admin panel to Write > Page to create a new page.

write page

Type “Guestbook” as the page title. Compose a brief introduction for the page content.

Ex. Please Sign My Guestbook!

7. On the right-hand side, pick Guestbook as the page template.

pick template

8. Save the page. If you don’t want your guestbook to display the post date, browse to Presentation > Theme Editor > guestbook.php

Look for:


<?php the_time('Y/m/d') ?>

And delete it. Click Update File to save.

Voila! You now have a guestbook!

I tried my best to make these instructions as painless as possible. If you’re still having issues, please don’t hesitate to leave me a note. Enjoy your new guestbook.

 


Thanks to http://www.alleba.com/blog/2006/06/09/how-to-create-a-wordpress-guestbook-reloaded/ for this how-to.