TUTORIAL: How to install PHP and MySQL on IIS

  • Crumpybumpy
  • Born
  • Born
  • No Avatar
  • Joined: 13 Jan 2008
  • Posts: 1
  • Status: Offline

Post January 13th, 2008, 7:20 am

I went through all of your steps..my set up is:

My setup:

WinXP Pro
IIS 5.1
PHP Version 5.2.5
MySQL Server 5.0
PHPMyAdmin 2.11.3

PHP works, and I can log onto MYSQL. When I try to run phpmyadmin i get:

"phpMyAdmin - Error
Cannot start session without errors, please check errors given in your PHP and/or webserver log file and configure your PHP installation properly."

Where are these logs under IIS?

Any pointers on how to troubleshoot this? I had all of this running well about 2 years ago but that must have been with older versions of everything......
  • Anonymous
  • Bot
  • No Avatar
  • Joined: 25 Feb 2008
  • Posts: ?
  • Loc: Ozzuland
  • Status: Online

Post January 13th, 2008, 7:20 am

  • ATNO/TW
  • Super Moderator
  • Super Moderator
  • User avatar
  • Joined: 28 May 2003
  • Posts: 20532
  • Loc: Pittsburgh PA
  • Status: Offline

Post January 13th, 2008, 7:37 am

turn on php error reporting to see what the exact error is. Here's a couple ways to do it

http://www.blizzard-media.com/hosting/q ... /id/6.html
http://www.wallpaperama.com/forums/how- ... -t453.html

The easiest way is to just edit your php.ini file
display_errors = On
Boasting Rights Sports Forums and Pools. NFL 2008-2009 pool is available now! Sign up and play for free in the Slingin' Sammy's NFL Pool forum!
Nuclear Services - www.alaron-nuclear.com
  • rayeniguard
  • Newbie
  • Newbie
  • No Avatar
  • Joined: 12 Jan 2008
  • Posts: 7
  • Status: Offline

Post January 13th, 2008, 10:11 am

Hey CrumpyBumpy,

I experienced the same error with PHP. The error message is vague. So, a solution for one may not be a solution for the other. Nevertheless, I'll tell you what I did.

In the php.ini file, I enabled the extension=php_mbstring.dll under the dynamic extensions section.

The IIS log files are located at:

C:\WINDOWS\system32\Logfiles\W3SVC1
  • rayeniguard
  • Newbie
  • Newbie
  • No Avatar
  • Joined: 12 Jan 2008
  • Posts: 7
  • Status: Offline

Post January 13th, 2008, 8:41 pm

I spoke too soon.

Yes, the last test script I posted tells me that the user connected successfully. However, when I view MySQL Administrator, I see no connect.

Troubleshooting continues...
  • rayeniguard
  • Newbie
  • Newbie
  • No Avatar
  • Joined: 12 Jan 2008
  • Posts: 7
  • Status: Offline

Post January 14th, 2008, 5:49 pm

Finally, I found my error.

<?php is needed as opposed to <? when opening a php script.
  • Rich_Bailey77
  • Newbie
  • Newbie
  • User avatar
  • Joined: 07 Feb 2008
  • Posts: 8
  • Status: Offline

Post February 7th, 2008, 10:34 am

Thank you ATNO/TW for the great tutorial. MySQL Administrator is a great tool (first time I've seen it).

Thank you too for taking the time to help all us noobs with this setup.

Now for my issue. I'm trying to setup PHPBB for our gaming group and just can't get it to work. It seems that PHP is installed correctly (I get the info.php screen ok see: http://forum.questersguild.com/info.php). It seems that MySQL is installed correctly (I get the part where I enter password in MySQL monitor and log in successfully). However, when I go to the setup for PHPBB it doesn't show MySQL as being installed (http://forum.questersguild.com/install/ ... anguage=en). In MySQL Administrator it shows 3 databases: information_schema, mysql and test.

I've totally removed everything (PHP, MySQL, PHPBB) and reinstalled without luck. I did get stuck on one thing during your tutorial, the part about editing the php.ini file. I don't have one in my C:\Windows directory so I edited the one in my C:\PHP directory. C:\PHP is in my path so that should work.

I'm a newbie with PHP, PHPBB and MySQL so I may have missed an easy thing but I'm just at a loss right now. Thank you for any help you can give me.

P.S. I did try the PHPBB forums and was unable to get any help.
Rich

"When everyone is out to get you, paranoia is just smart thinking."
  • ATNO/TW
  • Super Moderator
  • Super Moderator
  • User avatar
  • Joined: 28 May 2003
  • Posts: 20532
  • Loc: Pittsburgh PA
  • Status: Offline

Post February 7th, 2008, 12:17 pm

Use MySQL administrator to create a new database. By default phpbb2 used forumdata as a database name (however you can name it anything you want). Then create a user in MySQL Admin and grant that user rights to the new database. phpbb does not create the database for you. You have to do that first. Then in the install enter the username and password of the user you assigned rights to the database. Then the phpbb install will create the tables and populate the database for you.


Then try the phpbb install. Make sure your config.php file is writeable by all.

btw, thanks for the compliments. Much appreciated.
Boasting Rights Sports Forums and Pools. NFL 2008-2009 pool is available now! Sign up and play for free in the Slingin' Sammy's NFL Pool forum!
Nuclear Services - www.alaron-nuclear.com
  • Rich_Bailey77
  • Newbie
  • Newbie
  • User avatar
  • Joined: 07 Feb 2008
  • Posts: 8
  • Status: Offline

Post February 11th, 2008, 2:36 pm

You especially deserve the compliments. I realize how much time it takes to do your life, work and still moderate a forum like this.

Sorry it took me so long to try this out. That whole life thing keeps getting in the way. :wink: This is what I have so far.

I had an existing database from a previous install on an Apache server called php so I moved the folder to the "C:\MySQL\MySQL Server 5.0\data" folder. Restarted MySQL service and I can see it fine in MySQL Administrator. I then created a user called phpbb and assigned all privelages to that user. (see my screen shots)

I then checked the permissions on the config.php in the forum directory and they are set so everyone can write, read and execute and modify.

Launching the install for phpbb still shows MYSQL as unavailable.

I would be happy to try a totally new database but I don't know where to create one in MySQL Administrator.

Thanks again for your help and if you need information I'm not including please ask me because I'm not sure what else you may need.

Screen shots:
ImageImage
Rich

"When everyone is out to get you, paranoia is just smart thinking."
  • n_oandasan
  • Newbie
  • Newbie
  • No Avatar
  • Joined: 08 Feb 2008
  • Posts: 10
  • Loc: Philippines
  • Status: Offline

Post February 12th, 2008, 5:55 am

fdfsfs
  • Rich_Bailey77
  • Newbie
  • Newbie
  • User avatar
  • Joined: 07 Feb 2008
  • Posts: 8
  • Status: Offline

Post February 12th, 2008, 6:54 am

That is an advertising web search page. Why go there n_oandasan?
Rich

"When everyone is out to get you, paranoia is just smart thinking."
  • ATNO/TW
  • Super Moderator
  • Super Moderator
  • User avatar
  • Joined: 28 May 2003
  • Posts: 20532
  • Loc: Pittsburgh PA
  • Status: Offline

Post February 12th, 2008, 9:48 am

Open config.php in an editor. By default it is blank. If anything is in it, remove it and replace it with this:

[php]<?php


// phpBB 2.x auto-generated config file
// Do not change anything in this file!

$dbms = 'mysql';

$dbhost = 'localhost';
$dbname = 'php';
$dbuser = 'phpbb';
$dbpasswd = '******'; //password for phpbb user.

$table_prefix = 'phpbb_';

define('PHPBB_INSTALLED', true);

?>[/php]

Save it, then remove the install and contrib folders and try to access it in a browser:

http://localhost/phpbb/index.php (or the correct path to your forum)

If you get errors, post the exact error message.
Boasting Rights Sports Forums and Pools. NFL 2008-2009 pool is available now! Sign up and play for free in the Slingin' Sammy's NFL Pool forum!
Nuclear Services - www.alaron-nuclear.com
  • Rich_Bailey77
  • Newbie
  • Newbie
  • User avatar
  • Joined: 07 Feb 2008
  • Posts: 8
  • Status: Offline

Post February 12th, 2008, 2:10 pm

I made the change to the config.php file, removed the install directory and I did not have a contrib folder.

The error I get when I try http://forum.questersguild.com/index.php is:

The website cannot display the page        HTTP 500 
Most likely causes:
The website is under maintenance.
The website has a programming error.

What you can try:
Refresh the page.

Go back to the previous page.

More information


This PHP file (I copied from a website and put in the same directory with the index.php) pulls the date and seems to work fine: http://forum.questersguild.com/date.php

I put this because it seems PHP is working. The code I used for the date is

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
   "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Today's Date</title>
<meta http-equiv="content-type"
   content="text/html; charset=iso-8859-1" />
</head>
<body>
<p>Today's Date at Quester's Guild is <?php

echo date('l, F dS Y.');

?></p>
<p> </p>
<p> </p>
<p> </p>
<p> <h1>Check for our new forums coming soon.</h1> </p>

</body>
</html>
Rich

"When everyone is out to get you, paranoia is just smart thinking."
  • Rich_Bailey77
  • Newbie
  • Newbie
  • User avatar
  • Joined: 07 Feb 2008
  • Posts: 8
  • Status: Offline

Post February 12th, 2008, 2:18 pm

Sorry about the double post but I just removed everything in the forum directory and put all the files from the PHPBB3.0 zip download file (except the nice config.php file you just had me make) and I got the same results.

One other thing: in the config.php file where "$dbpasswd = '******'; //password for phpbb user. " is should I substitute the password for ******? Sorry if that is a dumb question but I hate assuming then being wrong. (I tried it both ways and neither worked.)
Rich

"When everyone is out to get you, paranoia is just smart thinking."
  • ATNO/TW
  • Super Moderator
  • Super Moderator
  • User avatar
  • Joined: 28 May 2003
  • Posts: 20532
  • Loc: Pittsburgh PA
  • Status: Offline

Post February 12th, 2008, 4:39 pm

yes, that was the idea.

Did you try the info.php file as suggested in the tutorial? If so, does it recognize and give information about MySQL? If it does, then the problem is a connection issue.
Boasting Rights Sports Forums and Pools. NFL 2008-2009 pool is available now! Sign up and play for free in the Slingin' Sammy's NFL Pool forum!
Nuclear Services - www.alaron-nuclear.com
  • Rich_Bailey77
  • Newbie
  • Newbie
  • User avatar
  • Joined: 07 Feb 2008
  • Posts: 8
  • Status: Offline

Post February 13th, 2008, 6:14 am

Yes, I did and it works great. I don't see anything about MySQL in the info.php. If the info can help you take a look at http://forum.questersguild.com/info.php

By connection issue what do you mean and would a MySQL reinstall help or what's my next step?

I was thinking through some stuff and maybe this has something to do with what is going on here (or I could just be throwing in a some unnecessary information :? ). I use host headers because I host several websites and as a result the http://localhost addresses will not work for the PHPBB stuff. Do I need to change something during the MySQL setup to point to the actual address for the forums rather than localhost?
Rich

"When everyone is out to get you, paranoia is just smart thinking."
  • Anonymous
  • Bot
  • No Avatar
  • Joined: 25 Feb 2008
  • Posts: ?
  • Loc: Ozzuland
  • Status: Online

Post February 13th, 2008, 6:14 am

Post Information

  • Total Posts in this topic: 142 posts
  • Moderator: Moderator Team
  • Users browsing this forum: No registered users and 100 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
 

© Unmelted Enterprises 1998-2008. Driven by phpBB © 2001-2008 phpBB Group.

 
 
 

Need a pre-made web design for your website?

Check out our templates here: Ozzu Templates