Wamp environment under Windows to build a picture sharing

Source: Internet
Author: User
Tags apache download php development environment php download phpmyadmin root access
This article is mainly for everyone to bring a Windows under the WAMP Environment Construction graphics and text tutorial (recommended). Small series feel very good, now share to everyone, also for everyone to make a reference. Follow the small series together to see it, hope to help everyone.

PHP Operating Environment:

Three ways to install Linux : Source package installation, RPM package installation, integrated environment installation (LNMP)

Two ways to install Windows: Single download installation, integrated environment installation (Appserv,phpstudy,wamp)

To install the PHP development environment on a Windows system:

The required software is individually installed:

Pre-Installation Preparation

Installing Apache

Install MySQL

Install PHP

Installing Phpmya

Software name

Download Address

Apache Download

http://httpd.apache.org/download.cgi

PHP download

http://www.php.net/downloads.php

Mysql

http://dev.mysql.com/downloads/mysql/, the free install version is selected here

PhpMyAdmin

Http://www.phpmyadmin.net

Apache Environment Installation:

Double-click Httpd-2.2.21-win32-x86-no_ssl.msi to start the installation. The installation Welcome screen appears.

Direct click "Next" to continue, the licensing agreement appears.

Select "I accept the terms in the license Agreement" to agree to the license agreement, then click "Next" to continue with the installation instructions.

Direct point "Next" next, appear fill information interface.

"Network domain" fills in your domain name, for example admin10000.com, if does not have the network domain name, may fill in casually.

"Server name" fills in your server name, such as Www.admin10000.com, which is the host name. If not, you can fill it out.

"Administrator's email address" fills in the system administrator's contact email, such as webmaster@admin10000.com. The contact email address is provided to the visitor when the system fails.

Tip: Because we install Apache mainly on this machine to do development, so the first 2 entries to fill out the localhost. The above 3 information can be filled in any time, you can modify this information in the httpd.conf file later.

Here are two options, the first is to install for all users of the system, use the default 80 port, and start automatically as a system service, and the other is to install only for the current user, use port 8080, and manually start. We chose the first "for all Users," on Port, as a service–recommended ". Then click "Next" to continue.

The Select installation type interface appears, typical is a typical installation, custom installs for the user, we choose typical here, press "Next" to continue.

Click "Change ..." To manually specify the installation directory. Here we have Apache installed to "D:\Apache\", where you decide where to install. It is recommended not to install on the operating system disk (usually C-drive), lest the operating system is broken, the restore operation has also cleared the Apache configuration file. After specifying the installation directory, click "Next" to continue.

Confirm that the installation options are correct and click "Install" to start the installation. If you think you want to check again, you can click "Back" to return to the check step-by-step.

The installation progress occurs, wait for a while, and then the following interface appears.

After clicking "Finish", a green icon will appear in the bottom right corner of the status bar.

Indicates that Apache has started normally.

At this time in the browser input http://localhost/or HTTP://127.0.0.1/can see the following interface.

MySQL installation :

Open the downloaded MySQL installation file mysql-5.0.27-win32.zip, double-click Unzip, run "Setup.exe", the following interface appears

Direct click "Next" to continue, the licensing agreement appears.

Select "I accept the terms in the license Agreement" to agree to the license agreement, then click "Next" to continue, in the window where you select the installation type, there is "typical (default)", "Complete", " Custom (user-defined) "Three options, we choose" Custom ", because through customization can let us more familiar with its installation process, for learning MySQL database is very helpful, click" Next "to continue to install:

In the Custom installation screen that appears, select the installation path of the MySQL database, where I set the "D:\Program File\mysql" and click "Next" to continue the installation:

Next go to the ready to install the interface, first confirm the previous settings, if wrong, press "back" to return, no errors, click the "Install" button to continue to install:

After clicking the "Install" button, the following installed interface appears, after a very little time, the MySQL database installation is complete, the interface of completing the MySQL installation appears:

This interface clicks "Next" on the line.

Note To select the "Launch the MySQL Instance configuration Wizard" option above, this is the configuration to start the MySQL, but also the most critical place (can also be set later), click the "Finish" button to enter the configuration interface.

MySQL database installation is very simple, the key is the installation after the completion of the configuration, click on the completion of the following Configuration Interface Wizard, click "Next" To configure:

In the Open Configuration Type window, select the mode of configuration, "Detailed configuration (manual precise configuration)", "Standard Configuration", in order to familiarize yourself with the process, we select "Detailed Configuration (manual and precise) ", click" Next "to continue:

In the window that appears, select the type of server, Developer machine (development test Class), Server machine (server type), dedicated MySQL server machine (dedicated database server), We are only used for learning and testing, the default is OK, click "Next" to continue,:

In the configuration interface that appears, select the purpose of the MySQL database, "Multifunctional database (General purpose)", "Transactional database Only", "non-transactional Database only (non-transactional) ", here I select the first item, generic installation, click" Next "to continue the configuration:

In the interface that appears, the InnoDB tablespace is configured, is to select a storage space for InnoDB database files, if modified, to remember the location, re-install the time to choose the same place, otherwise it may cause database corruption, of course, do a backup of the database is no problem ,:

On the page that opens, select the number of MySQL visits, simultaneous connections, "decision Support (DSS)/olap (20 or so)", "Online Transaction Processing (OLTP) (500)", " Manual Setting (manually set, set to 15) Select manual Settings Here, click "Next" to continue:

MySQL starts the TCP/IP network by default, the port number is 3306, and if you do not want to use this port number, you can change it through the drop-down list box, but you must ensure that the port number is not occupied. The ADD Filewall exception for this port check box is used to register the port number on the firewall, select this option here, the Enable Strict mode check box to start the MySQL Standard Model, In this way, MySQL will check the input data strictly, do not allow minor grammatical errors, for beginners do not recommend the choice of this item, so as not to cause trouble, I am here to check the selected, you can not select this option, click "Next" to continue:

In the Open character encoding page, set MySQL to use the character encoding, the first is the Latin code, the second is a multi-byte universal UTF8 encoding, the third is manual, we choose Utf-8, if there is no choice UTF-8 this encoding, in the use of JDBC connection to the database, will appear garbled, then need to add the following code "Useunicode=true&characterencoding=utf-8", can solve garbled problem, for the convenience of later so set to UTF-8 encoding, but there is a problem, That is, when using which console to insert Chinese characters, will error, query with Chinese characters table, unable to display Chinese characters, where you need to set a system parameter "set names GBK" after each entry to MySQL, you can solve the problem, next click "Next", continue to configure:

On the page that opens, choose whether to install MySQL as a Windows service, you can also specify the service name, or whether to add the MySQL bin directory to Windows PATH (after joining, you can directly use the file under Bin, Instead of pointing out the directory name, such as a connection, "Mysql–u username–p password;" Yes, click "Next" to continue with the configuration:

In the open page set whether you want to modify the default root user (the Super Administrator) password (default is empty), "New root password", if you want to modify, fill in the new password here, and enable the function of root remote access, do not create anonymous users, click "Next" to continue the configuration:

All the configuration operations have been completed here, click the Execute button to perform the configuration:

After a few minutes, the following UI appears to indicate that the MySQL configuration is over and that the message is successful.

Start the MySQL database in the service and enter "Mysql–h localhost–u root-p" or "mysql-h localhost-uroot-p password" in the command window, then enter the user's password in the prompt that appears:

PHP Environment Installation:

A. Installing Apache

B, install PHP (only need to extract the compressed package to the appropriate location)

C, PHP configuration

Rename Php.ini-dist to php.ini modify 486 and

Extension_dir = "D:/php-5.2.6/ext"

D. Configure Apache configuration file httpd.conf

#加载PHP模块LoadModule php5_module "D:/php-5.2.6/php5apache2_2.dll" #PHP配置文件所在位置PHPIniDir "d:/php-5.2.6" # What types of files will be referred to the PHP engine for processing AddType application/x-httpd-php. PHPE, restart Apache modify httpd.conf profile a) modify the 177th line to reset the document root DocumentRoot "D :/ftp/public/www "b) modify No. 244 line Site directory and document root directory to be consistent <directory" d:/ftp/public/www ">c) modify 187th row to set Web site root access rights <directory />options followsymlinksallowoverride Noneorder Allow,denyallow from all</directory>

d) Modify line No. 240 to set the default document for the site (if the HTML document you set does not exist, all files under the root directory of the Web site will be listed)

DirectoryIndex abc.html

e) Restart Apache service

PHP Configuration

LoadModule php5_module "D:\Program Files (x86) \apache software Foundation\php5.2.6\php5apache2_2.dll"

Phpinidir "D:\Program Files (x86) \apache software foundation\php5.2.6"

AddType application/x-httpd-php. php

This installs well, or is quite simple, is the step a bit more, exhausted me. If you feel the problem, please advise me a lot.

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.