PHP Just doesn't seem to work on my Win 2K Server

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
bobbert2512
Forum Newbie
Posts: 3
Joined: Fri Mar 12, 2004 6:18 am
Location: Swindon, UK

PHP Just doesn't seem to work on my Win 2K Server

Post by bobbert2512 »

:( I'm gonna freely admit now that I'm new to PHP and mySQL and have started playing with PHP pages on my website... I've started by trying to hang a guestbook off my site but I just cannot get it to work.

I have downloaded several free guestbook scripts for various sources and I just seem to keep getting the same results - Lot's of errors!

The type of guestbook I'm looking to implement is a PHP script using mySQL.

I have followed the installation instructions supplied with the 'guestbooks' to the letter - with no luck! What am I doing wrong/what have I missed???

At present I'm trying to use E-Guest sourced from http://www.script.leungeric.com but upon opening the guestbook page in IE6 I get loads of 'Notices' and 'Warnings' referring to 'Undefined Variable entries' in the php script. with some of what should be on the page displayed in a rather unformatted fashion.

Please feel free to take a look at http://www.nimas.org/EGuest/E-Guest_show.php (I have not yet secured this directory so please be gentle)

I have initialised the database and tables in mySQL but I guess it could be a problem associated with mySQL rather than PHP ... any thoughts?

My server setup : Win2k Server, Apache2, PHP 4.3.4, mySQL

Any help and advice would be greatly appreciated as I have no idea where to go with this from here.

Many Thanks in advance.
graphicmd
Forum Newbie
Posts: 8
Joined: Mon Jul 28, 2003 11:37 pm

Re: PHP Just doesn't seem to work on my Win 2K Server

Post by graphicmd »

bobbert2512 wrote:My server setup : Win2k Server, Apache2, PHP 4.3.4, mySQL
Why use win 2K server if you are going to install Apache?
Try installing PHP on IIS and see if you get it to work.
redmonkey
Forum Regular
Posts: 836
Joined: Thu Dec 18, 2003 3:58 pm

Post by redmonkey »

The 'undefeined variable' errors are most likely due to your error level set in the php.ini file, either reduce the error level reporting or define the variables before trying to use them. I prefer the later.

The 'mysql_num_rows()' warnings will probably be that your guest book is empty but the script has no taken this condition into consideration.

One of my development boxes is win2k which has a few different versions of Apache, PHP, mySQL, perl and python installed and I have no problems running PHP scripts.
bobbert2512
Forum Newbie
Posts: 3
Joined: Fri Mar 12, 2004 6:18 am
Location: Swindon, UK

Post by bobbert2512 »

Thanks for your input redMonkey.

Forgive my ignorance (I am new to all this) how do I define the variables before use?
bobbert2512
Forum Newbie
Posts: 3
Joined: Fri Mar 12, 2004 6:18 am
Location: Swindon, UK

Post by bobbert2512 »

Awesome .... That worked.

Thanks again for all your help!
Post Reply