Home php教程 php手册 IIS+PHP+MYSQL安装配置

IIS+PHP+MYSQL安装配置

Jun 06, 2016 pm 07:46 PM
download Install Configuration first

首先下载php-5.2.0-win32.zip,mysql-noinstall-5.0.22-win32.zip和phpMyAdmin-2.9.1.1-all-languages.zip。这三个文件的下载地址可以在百度搜索得到。 一、安装php 1) 在D盘新建一个名为PHP的文件夹,解压缩php-5.2.0-win32.zip到D:\PHP。 2) 在D:\PHP文件

首先下载php-5.2.0-win32.zip,mysql-noinstall-5.0.22-win32.zip和phpMyAdmin-2.9.1.1-all-languages.zip。这三个文件的下载地址可以在百度搜索得到。

一、安装php

    1) 在D盘新建一个名为PHP的文件夹,解压缩php-5.2.0-win32.zip到D:\PHP。

     2) 在D:\PHP文件夹下找到php.ini-dist文件,将其复制一份以做备份。将复制后的文件更名为php-ini。     

   3) 在php.ini文件中找到以下行:extension_dir = "./"(注:该行指定PHP查找扩展的位置),编辑该行,如下所示:

       extension_dir = "D:/PHP/ext"(注:不要这里用的是斜杠/而不是反斜杠\)。

     4) 在php.ini文件中找到以下行:;extension=php_mysql.dll(注:该行开始的分号指示PHP忽略该行),删除该行始的分号以启用扩展extension=php_mysql.dll;;extension=php_mbstring.dll 改成 extension=php_mbstring.dll  

     5) 保存并关闭php.ini文件;将修改好的php.ini文件复制到C:\Windows\文件夹下;

    6) 在D:\PHP\文件夹下找到名为php5ts.dll,libmysql.dll的文件,并将其复制到C:\windows\System32文件夹中 (注:IIS处理PHP 5和MYSQL需要该文件)。

至此,PHP安装完毕。

二、安装配置IIS

    1) 在控制面板中选择添加/删除程序,然后在弹出的对话框中选择添加/删除windows组件,勾中IIS即可。如果没有安装盘,可以去网下下一个从安装盘中抽取出来的iis包。安装完成后在C盘会有一个Inetpub的文件夹。

    2) 在管理工具中打开Internet 信息服务(IIS)管理器,或者在运行对话框中输入"inetmgr"(不包括引号)后确定。

     3) 在默认网站下新建虚拟目录,这里可以存放你的php文件。比如新建虚拟目录php指向电脑上的D:\phpamdin目录。在PHP文件夹上单击鼠标右键,选择"属性",依次点单击"虚拟目录"选项卡上的"配置",打开应用程序配置对话框。

    4) 在"映射"选项卡上点"添加",打开"添加/编辑应用程序扩展名映射"对话框,点击"可执行文件"后的"浏览",定位到D:\PHP\php5isapi.dll,在"扩展名"后的文本框内输入".php"(注:一定要注意扩展名前的句点),点击确定。

    5) 在文档选项卡中添加index.php做为默认文档。也可不添加。

    6) 再点"确定",退出"应用程序配置"对话框,再点"确定",退出PHP属性对话框。

至此,IIS配置完毕。

     某些配置可能需要重启服务器:cmd下使用:

        net stop w3svc

        net start w3svc

三、测试PHP安装

    1) 在D:\phpamdin下,(该目录在配置IIS时设置了虚拟目录为php)新建记事本文件后打开,输入以下代码:

       

                phpinfo();

        ?>        

        将该段代码保存成version.php(后辍名必须为php)。   

     2) 打开浏览器,在地址栏里输入localhost/php/version.php,如果显示正常,则PHP安装成功。

四、安装MYSQL

    1)在D盘新建一个名为mysql的文件夹,解压缩下载下来的mysql-noinstall-5.0.22-win32.zip到D:\mysql。

    2)运行D:\mysql\bin下的mysqld-nt.exe,会有一个dos画面一闪而过。这样就启动了mysql服务。

    3)在命令行下切换目录到D:\mysql\bin,键入mysql -u root -p 回车,如果提示Enter password: 则表示mysql安装成功。默认是空密码。

五、安装PHPMyAdmin

    1)将下载的phpMyAdmin-2.9.1.1-all-languages.zip中的全部内容解压缩到配置IIS时建立的D:\phpadmin目录下。

    2)启动浏览器,确保IIS和Mysql服务都在运行,键入http://localhost/php/index.php即可看到phpMyAdmin的管理画面。

Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Article

R.E.P.O. Energy Crystals Explained and What They Do (Yellow Crystal)
2 weeks ago By 尊渡假赌尊渡假赌尊渡假赌
Repo: How To Revive Teammates
4 weeks ago By 尊渡假赌尊渡假赌尊渡假赌
Hello Kitty Island Adventure: How To Get Giant Seeds
3 weeks ago By 尊渡假赌尊渡假赌尊渡假赌

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

What should I do if I download other people's wallpapers after logging into another account on wallpaperengine? What should I do if I download other people's wallpapers after logging into another account on wallpaperengine? Mar 19, 2024 pm 02:00 PM

When you log in to someone else's steam account on your computer, and that other person's account happens to have wallpaper software, steam will automatically download the wallpapers subscribed to the other person's account after switching back to your own account. Users can solve this problem by turning off steam cloud synchronization. What to do if wallpaperengine downloads other people's wallpapers after logging into another account 1. Log in to your own steam account, find cloud synchronization in settings, and turn off steam cloud synchronization. 2. Log in to someone else's Steam account you logged in before, open the Wallpaper Creative Workshop, find the subscription content, and then cancel all subscriptions. (In case you cannot find the wallpaper in the future, you can collect it first and then cancel the subscription) 3. Switch back to your own steam

How to download links starting with 115://? Download method introduction How to download links starting with 115://? Download method introduction Mar 14, 2024 am 11:58 AM

Recently, many users have been asking the editor, how to download links starting with 115://? If you want to download links starting with 115://, you need to use the 115 browser. After you download the 115 browser, let's take a look at the download tutorial compiled by the editor below. Introduction to how to download links starting with 115:// 1. Log in to 115.com, download and install the 115 browser. 2. Enter: chrome://extensions/ in the 115 browser address bar, enter the extension center, search for Tampermonkey, and install the corresponding plug-in. 3. Enter in the address bar of 115 browser: Grease Monkey Script: https://greasyfork.org/en/

What should I do if Baidu Netdisk is downloaded successfully but cannot be installed? What should I do if Baidu Netdisk is downloaded successfully but cannot be installed? Mar 13, 2024 pm 10:22 PM

If you have successfully downloaded the installation file of Baidu Netdisk, but cannot install it normally, it may be that there is an error in the integrity of the software file or there is a problem with the residual files and registry entries. Let this site take care of it for users. Let’s introduce the analysis of the problem that Baidu Netdisk is successfully downloaded but cannot be installed. Analysis of the problem that Baidu Netdisk downloaded successfully but could not be installed 1. Check the integrity of the installation file: Make sure that the downloaded installation file is complete and not damaged. You can download it again, or try to download the installation file from another trusted source. 2. Turn off anti-virus software and firewall: Some anti-virus software or firewall programs may prevent the installation program from running properly. Try disabling or exiting the anti-virus software and firewall, then re-run the installation

How to download Quark network disk to local? How to save files downloaded from Quark Network Disk back to the local computer How to download Quark network disk to local? How to save files downloaded from Quark Network Disk back to the local computer Mar 13, 2024 pm 08:31 PM

Many users need to download files when using Quark Network Disk, but we want to save them locally, so how to set this up? Let this site introduce to users in detail how to save files downloaded from Quark Network Disk back to the local computer. How to save files downloaded from Quark network disk back to your local computer 1. Open Quark, log in to your account, and click the list icon. 2. After clicking the icon, select the network disk. 3. After entering Quark Network Disk, click My Files. 4. After entering My Files, select the file you want to download and click the three-dot icon. 5. Check the file you want to download and click Download.

Introduction to how to download and install the superpeople game Introduction to how to download and install the superpeople game Mar 30, 2024 pm 04:01 PM

The superpeople game can be downloaded through the steam client. The size of this game is about 28G. It usually takes one and a half hours to download and install. Here is a specific download and installation tutorial for you! New method to apply for global closed testing 1) Search for "SUPERPEOPLE" in the Steam store (steam client download) 2) Click "Request access to SUPERPEOPLE closed testing" at the bottom of the "SUPERPEOPLE" store page 3) After clicking the request access button, The "SUPERPEOPLECBT" game can be confirmed in the Steam library 4) Click the install button in "SUPERPEOPLECBT" and download

Where to download files from Quark Network Disk_How to download Quark Network Disk to local area and share Where to download files from Quark Network Disk_How to download Quark Network Disk to local area and share Mar 21, 2024 pm 03:57 PM

As a convenient and practical network disk tool, Quark can help users easily obtain their favorite resources. What if you want to download a file locally? Let the editor tell you now, let’s learn it together! How to download Quark Network Disk to local sharing method 1. First open the Quark software, enter the homepage, and click the [Cloud Icon] on the lower right; 2. Then on the Quark Network Disk page, we click the [Document] function; 3. Then go to the document page, select the file you want to download, and click the [three-dot icon]; 4. After the final click, we click [Download] in the pop-up dialog box;

How to install Android apps on Linux? How to install Android apps on Linux? Mar 19, 2024 am 11:15 AM

Installing Android applications on Linux has always been a concern for many users. Especially for Linux users who like to use Android applications, it is very important to master how to install Android applications on Linux systems. Although running Android applications directly on Linux is not as simple as on the Android platform, by using emulators or third-party tools, we can still happily enjoy Android applications on Linux. The following will introduce how to install Android applications on Linux systems.

How to download foobar2000? -How to use foobar2000 How to download foobar2000? -How to use foobar2000 Mar 18, 2024 am 10:58 AM

foobar2000 is a software that can listen to music resources at any time. It brings you all kinds of music with lossless sound quality. The enhanced version of the music player allows you to get a more comprehensive and comfortable music experience. Its design concept is to play the advanced audio on the computer The device is transplanted to mobile phones to provide a more convenient and efficient music playback experience. The interface design is simple, clear and easy to use. It adopts a minimalist design style without too many decorations and cumbersome operations to get started quickly. It also supports a variety of skins and Theme, personalize settings according to your own preferences, and create an exclusive music player that supports the playback of multiple audio formats. It also supports the audio gain function to adjust the volume according to your own hearing conditions to avoid hearing damage caused by excessive volume. Next, let me help you

See all articles