Win2003 apache+php5+mysql4+phpmyadmin Easy installation Configuration _php Tutorial

Source: Internet
Author: User
Tags mysql download
First from the official website APACHE2.050, PHP5, MYSQL4.0.20, PHPMYADMIN2.57

Apache_2.0.50-win32-x86-no_ssl.msi
Php-5.0.0-win32.zip
Mysql-4.0.20d-win.zip
Phpmyadmin-2.5.7.zip

Operating system win2003 system disk: D-Disk

First step: Install Apache and configure support for PHP

Click Install File Apache_2.0.50-win32-x86-no_ssl.msi
Install Apache in the D:\apache2 directory (as you prefer)
Unzip the contents of the Php-5.0.0-win32.zip into the D:\php.
Locate the php.ini-dist in the PHP directory and rename it to php.ini and copy it to the Windows directory (Win2K Winnt)
As my php.ini is copied to the D:\windows directory.
Copy the Php5ts.dll,libmysql.dll in the PHP directory to the System directory (SYSTEM/SYSTEM32) as mine is D:\windows\system.

Configure the httpd.conf in Apache
Open D:\Apache2\conf\httpd.conf This file
Find Adddefaultcharset iso-8859-1 change it to Adddefaultcharset GB2312 (let default language encoding to Simplified Chinese)
Find DocumentRoot "D:/apache2/htdocs" to change it to your Web directory (not change) as my DocumentRoot "D:/website"
Find DirectoryIndex index.html Index.html.var in the back add index.htm index.php

Select installation Mode: Modular mode installation or CGI mode installation (optional)

--------------Modular Installation Configuration------------------------------------
Find #LoadModule Ssl_module modules/mod_ssl.so line, add a line after this line
LoadModule Php5_module D:/php/php5apache2.dll
Where D:/php/php5apache2.dll is in your PHP directory where Php5apache2.dll is located
Find AddType application/x-gzip gz. tgz line, add a line after this line
AddType application/x-httpd-php. php
---------------------------------------------------------------

--------------CGI installation configuration--------------------------------------
Find the AddType application/x-gzip gz tgz Line and add the following
scriptalias/php/"d:/php/"
AddType application/x-httpd-php. php
Action application/x-httpd-php "/php/php-cgi.exe"
---------------------------------------------------------------

At this point the PHP environment is basically configured successfully
Build a file named test.php in the Web root directory (such as my D:\website) as follows

Restart Apache Service
Open http://localhost/test.php with a browser
If you can see the PHP configuration output information is OK

Second step to install MySQL

Install MySQL to the specified directory, as my d:/mysql download is a non-installed MySQL compression package, directly extracted to the specified directory can be
Then click D:\mysql\bin\winmysqladmin.exe This file where D:\mysql is your MySQL installation directory
Enter winmysqladmin initial user, password (note: This is not MySQL user, password) do not care to fill in
After you have determined that your lower-right task's start-up bar will appear a traffic light icon, red light on behalf of the service stop, green light on behalf of the normal service, left click on the icon->winnt->install the service installation
Then left click on the icon->winnt->start the service to start the MySQL services

Modify the root password of the MySQL database
Enter the following command with CMD: (Note: D:\mysql is the MySQL installation directory)
CD D:\mysql\bin
Mysqladmin-u root-p Password 123456
Enter appears
Enter Password: (Note: This is to ask you to enter the original password. The password is empty at the time of installation, so enter directly)
In this case, the password for account root in MySQL was changed to 123456 installation completed

Third, configure the php.ini and test MySQL (php.ini for d:\windows php.ini)

Find Extension_dir = "./" To Extension_dir = "D:/php/ext"
Found it
; Extension=php_mysql.dll
Will '; ' Remove instead
Extension=php_mysql.dll
Found it
; Session.save_path = "/tmp"
Will '; ' Remove the directory where you saved the session, such as
Session.save_path = "D:/php/session_temp";

Restart Apache Service
The contents of the testdb.php file are established under the Web root directory (such as D:\website):
$link =mysql_connect (' localhost ', ' root ', ' 123456 ');
if (! $link) echo "fail";
else echo "Success";
Mysql_close ();
?>
Open http://localhost/testdb.php with your browser if the output success is OK

Iv. installation configuration of phpMyAdmin

Unzip the phpmyadmin-2.5.7.zip to the Web root and rename the folder to phpMyAdmin or other
Open config.inc.php in the phpMyAdmin directory
Found it
$cfg [' Servers '] [$i] [' user '] = ' root ';
$cfg [' Servers '] [$i] [' password '] = ' 123456 ';
Fill in your MySQL user and password separately.

If not used locally, it is best to add validation

I don't know if I wrote it right! But I'm basically the match! Is it supposed to be almost the same for learning?

http://www.bkjia.com/PHPjc/317142.html www.bkjia.com true http://www.bkjia.com/PHPjc/317142.html techarticle first from the official website of the APACHE2.050, PHP5, MYSQL4.0.20, PHPMYADMIN2.57 apache_2.0.50-win32-x86-no_ssl.msi php-5.0.0-win32.zip Mysql-4.0.20d-win.zip phpmyadmin-2.5.7.zip operation system ...

  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.