Home php教程 php手册 php5.4 和 apache2.2 环境配置

php5.4 和 apache2.2 环境配置

Jun 06, 2016 pm 07:58 PM
php5 php5.4 download environment Configuration

1: 下载php5.4.2 for windows. 要下载Thread Safe线程安全版的 php-5.4.2-Win32-VC9-x86.zip 2: 解压 后 php.ini-development 是开发版本的配置. php.ini-production 是网站发布时的配置. 使用开发版php.ini-development 修改成php.ini后 打开. 3: 下面修改p

1: 下载php5.4.2 for windows. 

要下载Thread Safe线程安全版的

 

php-5.4.2-Win32-VC9-x86.zip

2: 解压

php.ini-development 是开发版本的配置.

php.ini-production 是网站发布时的配置. 

使用开发版php.ini-development  修改成php.ini后 打开.

3: 下面修改php.ini的配置  我的php5.4.2是放在了E:\apache2.2\php-5.4.2文件夹下面,修改下面的为以下内容

Xml代码  php5.4 和 apache2.2 环境配置

  1. short_open_tag = On  ?>开启    
  2. asp_tags = On*  *>开启    
  3. register_globals = off              超级全局变量,建议关闭,打开它会造成安全上的漏洞    
  4. post_max_size8M                   POST提交时候的最大数据提交量    
  5. magic_quotes_gpc = off              php自带的安全验证,建议开启    
  6. file_uploads = On                   php支持文件上传    
  7. upload_max_filesize = 2M            文件上传最大值 2M     
  8. max_file_uploads = 20               同时并发上传的最大文件数    

 找到extension_dir 和下面很多的 extension= ****.dll 这里

在extension=****.dll 的前面加上这一段来配置php的动态链接库地址

 

Xml代码  php5.4 和 apache2.2 环境配置

  1. extension_dir="E:\apache2.2\php-5.4.2\ext"    
 

去掉以下的extension前面的分号 ;  使其开启

Php代码  php5.4 和 apache2.2 环境配置

  1. extension=php_bz2.dll    
  2. extension=php_curl.dll    
  3.    
  4. extension=php_gd2.dll    
  5. extension=php_gettext.dll    
  6.    
  7. extension=php_mbstring.dll    
  8. extension=php_mysql.dll    
  9. extension=php_mysqli.dll    
  10.    
  11. extension=php_openssl.dll    
  12. extension=php_pdo_mysql.dll    
  13.   
  14. extension=php_sockets.dll    
  15.   
  16. extension=php_xmlrpc.dll    

 找到date.timezone 

设置时区为中国时区

Java代码  php5.4 和 apache2.2 环境配置

  1. date.timezone = prc    

 

4: 让Apahce支持php.

打开.\apache2.2\conf\httpd.conf

在大约60行的位置添加

Java代码  php5.4 和 apache2.2 环境配置

  1. PHPIniDir "E:/apache2.2/php-5.4.2"  

 

注意一定要添加在LoadModule 那一段的前面,以便提前加载,不然稍后的phpMyAdmin容易出错.

 

在LoadModule这段后面添加

Java代码  php5.4 和 apache2.2 环境配置

  1. LoadModule php5_module "E:/apache2.2/php-5.4.2/php5apache2_2.dll"    

 

 

在大约380行Addtype那里加入

Java代码  php5.4 和 apache2.2 环境配置

  1. AddType application/x-httpd-php .php .php5 .php4 .php3 .phtml .phpt    
  2. AddType application/x-httpd-php-source .phps    

 

5: 重启Apache 

在E:\apache2.2\htdocs 建一个phpinfo.php 测试

Php代码  php5.4 和 apache2.2 环境配置

  1. phpinfo();    
  2. ?>    

 

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

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Roblox: Bubble Gum Simulator Infinity - How To Get And Use Royal Keys
3 weeks ago By 尊渡假赌尊渡假赌尊渡假赌
Mandragora: Whispers Of The Witch Tree - How To Unlock The Grappling Hook
3 weeks ago By 尊渡假赌尊渡假赌尊渡假赌
Nordhold: Fusion System, Explained
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)

Hot Topics

Java Tutorial
1668
14
PHP Tutorial
1273
29
C# Tutorial
1256
24
How to download episodes of Hongguo short drama How to download episodes of Hongguo short drama Mar 11, 2024 pm 09:16 PM

Hongguo Short Play is not only a platform for watching short plays, but also a treasure trove of rich content, including novels and other exciting content. This is undoubtedly a huge surprise for many users who love reading. However, many users still don’t know how to download and watch these novels in Hongguo Short Play. In the following, the editor of this website will provide you with detailed downloading steps. I hope it can help everyone in need. Partners. How to download and watch the Hongguo short play? The answer: [Hongguo short play] - [Audio book] - [Article] - [Download]. Specific steps: 1. First open the Hongguo Short Drama software, enter the homepage and click the [Listen to Books] button at the top of the page; 2. Then on the novel page we can see a lot of article content, here

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/

The working principle and configuration method of GDM in Linux system The working principle and configuration method of GDM in Linux system Mar 01, 2024 pm 06:36 PM

Title: The working principle and configuration method of GDM in Linux systems In Linux operating systems, GDM (GNOMEDisplayManager) is a common display manager used to control graphical user interface (GUI) login and user session management. This article will introduce the working principle and configuration method of GDM, as well as provide specific code examples. 1. Working principle of GDM GDM is the display manager in the GNOME desktop environment. It is responsible for starting the X server and providing the login interface. The user enters

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

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

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.

How to download Beilehu children's songs How to download Beilehu children's songs Mar 28, 2024 am 11:10 AM

As an indispensable accompaniment to children's growth, Beilehu's children's songs have won the love of countless parents and children with their cheerful melody, vivid pictures and entertaining and educational content. In order to allow babies to enjoy the joy brought by children's songs anytime and anywhere, many parents hope to download Beilehu's children's songs to their mobile phones or tablets so that they can listen to their children at any time, but how to save Beilehu's children's songs? On your mobile phone, this tutorial will bring you a detailed introduction. Users who don’t understand it yet can come and read along with this article to learn more. Beilehu Nursery Rhymes Download Children's Songs Multi-Picture Tutorial: Open the software and select a children's song you want to download. The editor takes "Classic Children's Songs" as an example. 2. Click the "Download" button below the children's song star.

See all articles