"Personal note" 003-php basic -01-php Quick Start -03-php Environment setup

Source: Internet
Author: User
003-php Basic -01-php Quick Start 03-php Environment setup

1. Client (browser)

IE FireFox CHROME Opera Safari

2. Server

Is the basic of running the website

is where the program code is placed

Environment: Apache/nginx

Development environment: Xamp/wamp

X:linux/ios/windows

A:apache

M:mysql

p:php

Server environment: LAMP

Linux

Apache

Mysql

Php

Note: The above is the mainstream development environment and server environment, is not absolutely such a combination

How to build a server

1. Integrated installation Environment

2. Individual configuration (relatively complex compared to novice)

3. Using XAMPP to build the server

What is 1.XAMPP?

XAMPP (Apache+mysql+php+perl) is a powerful built-in XAMPP software station integration package

    

Figure-1

2.XAMPP Download Address

Https://www.apachefriends.org/zh_cn/index.html

Download the appropriate installation package according to your own system

My operating system is Windows 10, I will download the latest version of (XAMPP for Windows v5.6.3 (this version may not be the latest version)) (-2)

    

Figure-2

Note: This content page shows the latest version of the latest version of XAMPP for Windows that is no longer supported for Windows XP and Windows Server 2003.

Windows XP and Windows Server 2003 can click the "download click here for other versions" tab to download the previous version.

Then it jumps to this page (-3)

Normally the Download File window (-4) is automatically exhaled, and if not, click "Click here"

    

Figure-3

Select Save location, click "Download" (-4)

    

Figure-4

3. Installing the XAMPP Integration pack

Download the good file (-5), right-click "Run as Administrator" (for users above the Windows 7 version)

    

Figure-5

Click "NEXT" to continue (-6)

    

Figure-6

The default is to install all components (-7)

    

Figure-7

I only install the necessary components and I need the components, other FTP server, mail server and so I temporarily useless to install, choose to continue to point to "next" next (-8)

    

Figure-8

Select the installation path

Note: The default is installed on the C drive, is not recommended to install in the system disk, I choose to install on the D drive

After selecting the installation path, click "Next" to proceed to the next step (-9).

    

Figure-9

Here's a check box saying "Learn more about Bitnami XAMPP", check box to remove! (-10)

    

Figure-10

Click "Next", Next (-11)

    

Figure-11

Click "Next" Next, ready to install (-12)

    

Figure-12

Installation in ... Mo Turn Away ... (-13)

    

Figure-13

Installation Complete

Ask: "Do you want to start the Contrl panel now" If you want to open the Control Panel right away, check it by default. Click Finish (Finish). (-14)

    

Figure-14

============================= Gorgeous split-line =====================

4.apache solutions that do not start properly (solutions that are not all problems)

Normally the installation has been completed and the XAMPP Control Panel can start normally, but there are special cases: (-15)

  

Figure-15

Probably means that the default port 80 is occupied by other programs. All Apache does not work properly.

Since I have previously installed IIS, the default port is also 80

There are two options here

1, kill the application of 80 ports (such as the IIS inside my computer, a bit brutal ...) )

2. Modify Apache Default port

Because IIS I'm also using to publish the ASP, here I choose to modify the Apache default port

How to modify the Apache default port (two ways)

1. First: Click on the "Config" button on the Apache line in Xampp Control Panel to display the menu, click Apache (httpd.conf); (-16)

    

Figure-16

The httpd.conf file is then opened automatically. (-17)

    

Figure-17

The second way: Find the httpd.conf file (where is this file)

Contents of the httpd.conf: path\xampp\apache\conf

Path is xampp installed directory, I choose to install on the D drive, so my httpd.conf directory is: D:\xampp\apache\conf (-18)

    

Figure-18

I like the second way, because it's usually better to make a backup before modifying the file.

Where to modify (two places to change)

1. "Listen 80" changed to "Listen 81" (Can not be 81,8080, can not be used by other programs to use the port)

Modified before (-19)

        

Figure-19

Modified (-20)

        

Figure-20

2. "ServerName localhost:80" changed to "ServerName localhost:81"

Modified before (-21)

        

Figure-21

Modified (-22)

        

Figure-22

Save.

Launch Apache

Click on the Apache line corresponding to the "Start" is actually the Apache typeface background color to light green when it is normal to use.

But why the red, which is related to the xampp inside the settings INI file, xampp default initialization file INI inside the initialization of Apache default port number is still 80.

Then when initializing to the specific Apache file, the discovery port number is already 81 after the modification.

So it's normal.

However, although the Pao Hong can run, but see always make people unnatural, in short, is uncomfortable. (-23)

        

Figure-23

How to Solve

If it is already started, click "Stop" on the Apache line to temporarily stop the operation.

Then look at the hand chart ( -24,-25)

        

Figure-24

        

Figure-25

Change (-25) The place labeled "3" to 81, then click on "Save" labeled "3" to save, click "Save" labeled "2" to save.

Click Stop to start Normal startup ... (-26)

        

Figure-26

Apache has started normally (-27)

        

Figure-27

Finally, you can click the XAMPP control Panel "Quit" Exit button to close the Xampp dashboard. (Figure-28)

        

Figure-28

============================== Gorgeous split-line ===========================

5. Test the installation Environment

Browser: (URL) Address bar type: localhost:81 (type localhost if the port is 80 by default), enter. The following page appears this indicates that the XAMMP installation (configuration) has succeeded. (-29)

  

Figure-29

  • Related Article

    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.