The first thing you need to do is go to www.php.net and download a windows version of php3 or php4. I recommend that you start with php3 since all the problems you about to have will have been solved....here
at this forum.
When you get php3 un-zip it into a directory c:\php3.
Then go to http://www.apache.org/dyn/closer.cgi to find
a copy of apache....don't always grab the latest version.....most people here are using something like version 3.16 or something like that. This will self-extract into c:\program files\apache group\apache and in this dir there should be a directory called htdocs.....this is where you can put all of your html and php files, etc.
then go to http://www.mysql.com/mirrors.html
and grab the windows version of mysql.... which will self-extract into c:\msql
Then get a file called browscap.ini from
http://cyscape.com/browscap/ or
http://asptracker.com/browscap.zip and unzip it anywhere.
Double click on it's exe file and a file
called browscap.ini should be created. Put this file in c:\windows.
Boy......here we go....the fun starts!
In the c:\php3 dir there will be a file called php3-dist.ini....... remove
the "-dist" from this so it is called just php3.ini.
I recommend opening this file in a program that lets you see the line #'s.
Do the following to the file.
Under "Paths and Directories" change the extension_dir to point to:
extension_dir = C:/php3
Next under "Dynamic Extensions" add:
cgi_ext=php3
And under "browscap" change it to read:
browscap = C:/Windows/browscap.ini
Also under "Dynamic Extensions", windows extenstions change:
;extension=php3_mysql.dll
to extension=php3_mysql.dll
Also, uncomment anything else that you might want to use like gd.dll
All your doing is removing that line from being commented. You also need to get rid of the semicolon
"
; " before the browscap line if you didn't.
COPY THE ABOVE FILE INTO C:\windows
Now APACHE
There should be a file called httpd.conf in c:\program files\apache group\apache
Edit the following
First search for "#ServerName". Change that line to read:
ServerName
http://localhost
(Note: Be sure to take out the "#" - this is known as a comment mark which basically means "ignore everything on this line")
Next change the DirectoyIndex to:
DirectoryIndex index.php3
Around line 458 you will need to change the
ScriptAlias:
ScriptAlias /php3/ "c:/php3/php.exe"
Around line 506 add this:
AddType application/x-httpd-php3 .php3
Around line 643 add:
Action application/x-httpd-php3
"/cgi-bin/php.exe"
or
Action application/x-httpd-php3
"c:/usr/bin/cgi-bin/php.exe"
Save it and close the file
Open up Notepad and write the following code:
<?php
phpinfo()
?>
Save it in c:\program files\apache group\apache\htdocs
as info.php3.
Now open your browser and type in the following in the url bar:
http://localhost/info.php3
You should be seeing a big ugly table with colors and stuff.....and showing you what version of php you have, etc.
If not (and I doubt that you are) go over the files that you have edited and check for code errors. Also, any errors that the browser displays......write them down for when you email me screaming that I've put you crook.
MYSQL
If this has worked.......go and download phpmyadmin from www.phpwizard.net and unzip it into your htdocs folder. Make a shortcut to this folder for your desktop cos' you'll be in and out of it a lot.
Open up the config.inc file and put in these:
$cfgServers[1]['host'] = '';
should be changed to
$cfgServers[1]['host'] = 'localhost';
$cfgServers[1]['stduser'] = ''; should be changed to
$cfgServers[1]['stduser']
= 'root';
$cfgServers[1]['stdpass'] = ''; should remain the same for now.
Save
it!
Go to your windows dos prompt and type:
cd mysql
cd bin
mysql --install
mysqld
Hopefully you didn't get a beeping noise?
Let me know if you
did!
Now type into
your browser: http://localhost/phpmyadmin/index.php3
and see what happens.......you should be seeing a framed page with some databases to the left of your screen?
Thats it~!
I hope to hell this works..........it's been a long while for me......please don't yell at me when you get bombarded with errors...I will try to do what I can to help, but I'm no expert.
Best of luck
regards,
Piyush