How to set up a PHP server

Source: Internet
Author: User
Tags iis ini php file php server port number

How to set up a PHP server

"One" Download the software first:

(Apache) I used the apache_2.24-win32-x86-no_src!! that was downloaded in the Hurricane Software park.

Download Address: http://www.pc6.com/SoftView/SoftView_2253.html

(jdk!) There is a connection above the home page.

(PHP4) Do not have to say more code-labs above there are also can go to the official website of PHP to see!!

Download Address: http://www.pc6.com/SoftView/SoftView_2165.html

(iasp) One of the most important software ——————————————————————————————————

"Two" Install Apache

1, double-click the Apache installation files, and ordinary Windows program installation, the way point "next" can be.

2, installation program requires you to enter your network domain (network domain name: such as xxx.com), server domain (server domain name: Form www.xxx.com) and webmaster e-mail. Some words on the actual fill in, individual users if not, you can fill in the format casually.

3, to choose the installation path, I strongly recommend that you change the installation path to "C:" Because this can save a lot of configuration trouble. 4, all the way "next" until "Finish". The installation is over.

At this point, your Apache has been started, you can enter in the IE Address bar: http://localhost/or http://127.0.0.1 to see. In the "management tool" in the "service" item, you can also find the Apache service figure, after the Apache can serve as a windows2000 service, with the machine to start and run!

------------------------------------------------------------------------------

"Three" configuration Apache

To open a profile the main modified items are:

(1), find DocumentRoot. This statement specifies your site's path, which is the directory where your home page is located. You can use the default, or you can specify one yourself, but remember, do not add "/" at the end of this sentence.

(2), find to DirectoryIndex. This is the homepage of your first display, add index.htm index.php index.php3 index.cgi index.pl index.asp, and so on after the index.html. Note that you have to leave a space between each type!

(3), the special note is port (port number), if not installed IIS, keep 80 do not change, otherwise, it is necessary to change (because IIS Web Services occupy 80), can be changed to 81, etc., or simply change the default port number of IIS! Be happy with you.

(4). #bindaddress * Changed to bindaddress 127.0.0.1 (open with Notepad/Then click Edit/Find)

The other is to be used in depth to configure the project! Run http://localhost/after installation

You can see the Apache Help file!

-----------------------------------------------------------------------------

"Four" Install XXX (note this most important) (Turn off the Apache service)

(1), the following installation of PHP first installed PHP to C:PHP4 (do not change the path!) otherwise later configuration .... I'm using PHP's 4.0.2 version,

(2), next to the copy Msvcrt.dll to c:winntsystem32 the following system to prompt the file is being used by Windows, does not matter normal phenomenon! Overwrite any existing files.

(3), the c:php.ini-dist renamed to PHP.ini, copy to C:winnt,

(4), OK now open the Apache configuration file httpd.conf Add the following statement: (Wherever you want, but to go alone)

scriptalias/php4/"c:/php4/"

AddType application/x-httpd-php4. php

AddType APPLICATION/X-HTTPD-PHP4. php3

AddType APPLICATION/X-HTTPD-PHP4. PhP4

Action Application/x-httpd-php4 "/php4/php.exe"

DirectoryIndex index.html

DirectoryIndex index.htm

DirectoryIndex index.php

DirectoryIndex index.php3

DirectoryIndex INDEX.PHP4

DirectoryIndex index.asp

(5), then modify the php.ini file

Find Windows Extensions items: increasing

Extension_dir = C:PHP4

Extension=php_zlib.dll

Extension =php_ldap.dll

Extension =php_zlib.dll

Extension =php_calendar.dll

Extension =php_exif.dll

Extension =php_ftp.dll

Extension =php_mssql70.dll (don't add this one, no mssql7.0)

Extension =php_imap.dll

OK save Ko

Create a test.php file in your DocumentRoot directory

OK see the test page of PHP!! The configuration of PHP has been completed!

Installing the JDK below is also a default installation! Then add the path variable value c:j2sdk*bin (*: Different versions of the installation pathname) in Windows environment variables.

All right, here's the installation iasp. Use the default installation on it! After the installation process the software prompts you to set the Web server first by selecting:

Instant ASP native servlet surport option next select Apache Server

Then ask you to choose Apche version number and httpd.conf path selection after the system automatically configured if everything goes well can be tested!!

Establish test.asp

<%response.write ("Hell world!") %>

Now run http://localhost/test.asp, see helloworld! Okay, everything's done. You can use Apache!!!

------------------------------------------------------------------------

"Five", the above mentioned windows+apache+php+asp operating environment today to say on this basis so that Apache can also support the operation of JSP.

1: Required software resin (resin2.1.4) Resin http://www.caochu.com

Let's talk about how to install:

Resin after downloading is a. zip file as long as the simple solution to the specified directory can be used here I am using c:resin-ee-2.1.4 command C:resin-ee-2.1.4binhttpd.exe-install (remove) To resin as a service for Win2000

ok! Find the environment variable "Control Panel--> system--> Advanced--> environment variable" below Win2000

Add variable "resin_home" Variable Value "c:resin-ee-2.1.4" if you already have the JDK installed then you don't need to set anything!

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.