search
HomeBackend DevelopmentPHP TutorialPHP&MYSQL server configuration instructions_PHP tutorial


Apache 1.3.22 for Win32+PHP 4.0.6+Active Perl 5.006001+Zend Optimizer v1.1.0+mod_gzip 1.3.19.1a+MySQL 4.0.0 Alpha
Apache 1.X for win32 Although the performance is poor (and IIS It's too far behind, I hope 2. PHP-4 has the characteristics of fast execution and high performance efficiency. PERL provides perl-cgi support, Zend Optimizer accelerates PHP programs, mod_zip is used to compress web server output data, and MySql is the database. The following is based on win2k/xp. It is too troublesome to run these service software on win9x and cannot be run as a service.

1.
Download location of each software:
Apache: http://www.apache.org/dist/httpd/binaries/win32/
PHP: http://www. php.net/downloads.php (Download .zip version)
Active Perl: http://www.activestate.com/Products...l/download.plex (Download win32)
Zend Optimizer: http: //www.zend.com/store/getfreefi...pid=13&zbid=198
mod_gzip: http://www.remotecommunications.com/apache/mod_gzip/ (download .dll)
MySQL: http: //www.mysql.com/downloads/index.html
Other software:
phpMyAdmin: http://sourceforge.net/project/show...release_id=44593 (for database control operations)

2.
Installation path (the following is an example, you can install it casually, but it is best not to install it in a path with a long name)
Apache: d: apache
PHP: d: php
Perl: d:perl
MySQL: d:mysql
mod_gzip: Unzip in d:apachemodules
Zend Optimizer: Unzip in d:php
Website file placement: d:myweb
phpMyAdmin: Unzip in d:mywebphpmyadmin
Windows: d:windows

3. Configure mysql
After installation, winmysqladmin will automatically run and prompt for username and password. Enter username and password. Default In this case, it has been installed as NT Service. If you need to be more secure, then modify the default port on the my.ini Setup page of winmysqladmin under port=port, and modify the username and password below. After modification, click Save Modification on the left to save the settings, then right-click on the console form and select WinNT->Stop The Service->Start The Service, so that the new settings will take effect.

4. Configure php
Rename php.ini-dist to php.ini and open the modification.
Add
zend_optimizer.optimization_level=15 in the next line of [php]
zend_extension_ts="d:phpZendOptimizer.dll"
The path to zendoptimizer.dll must match

Then search extension_dir, add the full name of your windirsystem32 directory at the end, for example: extension_dir = d:windowssystem32 (the last one must not be omitted!)
Look for extension=php_exif.dll, extension=php_imap.dll, extension=php_ldap.dll, extension=php_zlib.dll, remove the previous semicolon comment
Look for mysql.default_port, add your mysql port after the equal sign, for example: mysql.default_port = 3306 (3306 is the default port of mysql)
Look mysql.default_host, add localhost after the equal sign, for example: mysql.default_host = localhost
Save
Copy php.ini php.exe to the windows directory, and copy php4ts.dll, dlls and extensions under the directory in php Copy all .dll files to windowssystem32 (do not overwrite existing files)

5. Configure Apache
Open the apacheconfhttpd.conf file, the following are the main settings
ServerType standalone

ServerRoot "d:/Apache"
# Apache installation directory

PidFile logs/httpd.pid
ScoreBoardFile logs/apache_runtime_status
Timeout 300
KeepAlive On
MaxKeepAliveRequests 100
KeepAliveTimeout 15
MaxRequestsPerChild 1024
ThreadsPerChild 50
SendBufferSize 65536
MaxClients 150
Listen 80
# Listen on port 80, default web server port
BindAd dress *
# is Any IP can use web server

LoadModule vhost_alias_module modules/mod_vhost_alias.so
AddModule mod_vhost_alias.c
# Remove the # in front of these two lines to enable virtual domain name support

Port 80
ServerAdmin me@localhost
ServerName localhost
# Port, administrator email, server domain name, modify according to actual conditions

DocumentRoot "d:/myweb/"
# web file Save the address, here is d:/myweb as an example

Options FollowSymLinks MultiViews
AllowOverride all
Order allow,deny
Allow from all

# Set access options for d:/myweb
ScriptAlias ​​/cgi-bin "e:/myweb/cgi"

AllowOverride None
Options None
Order allow,deny
Allow from all

# Set cgi-bin directory permissions

#!/perl/bin/perl
# This line configures the running environment of perl-cgi. Since Active Perl is installed in d:perl, the relative path is used directly here
# Note that the cgi and pl to be run The first line of the file must be the same as here, otherwise it will not run.It can also be written here as
# #!d:/perl/bin/perl
# In addition, the first # in this configuration does not mean a comment, so it cannot be omitted! !

Find DirectoryIndex index.html and add below
DirectoryIndex index.htm
DirectoryIndex default.htm
DirectoryIndex default.html
DirectoryIndex index.php
DirectoryIndex index.php3
DirectoryIndex index.cgi

Find AddType application/x-httpd-php
Change to AddType application/x-httpd-php .php .phtml .php3

Find AddHandler cgi -script
Modify to AddHandler cgi-script .cgi .pl

LoadModule php4_module d:/php/sapi/php4apache.dll
LoadModule gzip_module d:/apache/modules/ApacheModuleGzip.dll
# Load php4, gzip module

### The following are gzip module settings
mod_gzip_on Yes
mod_gzip_minimum_file_size 300
mod_gzip_maximum_file_size 0
mod_gzip_maximum_inmem_size 1 00000
mod_gzip_keep_workfiles No
mod_gzip_dechunk Yes
mod_gzip_can_negotiate Yes
mod_gzip_temp_dir d:/apache/temp
# There must be a temp directory under the apache directory, if not, create a new one
mod_gzip_item_include file .html$
mod_gzip_item_include file .htm$
mod_gzip_item_include file .shtml$
mod_gzip_item_include file .shtm$
mod_gzip_item_include file .pl$
mod_gzip_item_include file .cgi$
mod_gzip_item_include mime^text /.*
mod_gzip_item_include handler ^perl- script$
mod_gzip_item_include mime ^httpd/unix-directory$
mod_gzip_item_include handler ^server-status$
mod_gzip_item_include handler ^server-info$
mod_gzip_item_include mime ^application/x-httpd -php
mod_gzip_item_include file .php$
mod_gzip_item_include file .php3$
mod_gzip_item_include file .mht$
mod_gzip_item_exclude file .css$
mod_gzip_item_exclude file .js$
mod_gzip_item_exclude mime ^image/.*
mod_gzip_item_exclude reqheader Content-Type:multipart/form-data
mod_gzip_item_exclude reqheader Content-Type:application/x-www-form-urlencoded

mod_gzip_item_exclude file attachment.php$
#The above is required for VBB Required
### End of mod_gzip sample config
LogFormat "%h %l %u %t "%r" %>s %b mod_gzip: %{mod_gzip_result}n In:%{mod_gzip_input_size}n Out:%{mod_gzip_output_size}n:%{mod_gzip_compression_ratio}npct." mod_gzip_info
# Record gzip operation status
# The above are the places that need to be added or modified in httpd.conf. Others do not need to be modified

6. Configure phpmyadmin
Open the config.inc.php file and modify it
$cfgServers[1]['host'] = 'localhost'; //mysql address
$cfgServers[1]['port' ] = '3306'; //mysql port
$cfgServers[1]['user'] = 'username'; //mysql username
$cfgServers[1]['password'] = 'passwd' ; //mysql password
$cfgDefaultLang = 'zh'; //Configure phpmyadmin as a simplified Chinese interface

Since phpmyadmin is a mysql configuration, it needs to be placed in a directory that others cannot guess or This directory requires user permission verification

7. Test
If you follow the default d:mywebphpmyadmin, then use a browser to open the following address http://localhost/phpmyadmin/
If the test is successful, phpmyadmin will appear On the mysql management page, click Show PHP information, or go to http://localhost/phpmyadmin/phpinfo.php. This shows the configuration and operation of web php mysql...
As long as you configure No problem, then the above Apache 1.3.22 for Win32+PHP 4.0.6+Active Perl 5.006001+Zend Optimizer v1.1.0+mod_gzip 1.3.19.1a+MySQL 4.0.0 Alpha is configured

www.bkjia.comtruehttp: //www.bkjia.com/PHPjc/314753.htmlTechArticleApache1.3.22forWin32+PHP4.0.6+ActivePerl5.006001+ZendOptimizerv1.1.0+mod_gzip1.3.19.1a+MySQL4 .0.0Alpha Apache1.
Statement
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
php怎么把负数转为正整数php怎么把负数转为正整数Apr 19, 2022 pm 08:59 PM

php把负数转为正整数的方法:1、使用abs()函数将负数转为正数,使用intval()函数对正数取整,转为正整数,语法“intval(abs($number))”;2、利用“~”位运算符将负数取反加一,语法“~$number + 1”。

php怎么实现几秒后执行一个函数php怎么实现几秒后执行一个函数Apr 24, 2022 pm 01:12 PM

实现方法:1、使用“sleep(延迟秒数)”语句,可延迟执行函数若干秒;2、使用“time_nanosleep(延迟秒数,延迟纳秒数)”语句,可延迟执行函数若干秒和纳秒;3、使用“time_sleep_until(time()+7)”语句。

php怎么除以100保留两位小数php怎么除以100保留两位小数Apr 22, 2022 pm 06:23 PM

php除以100保留两位小数的方法:1、利用“/”运算符进行除法运算,语法“数值 / 100”;2、使用“number_format(除法结果, 2)”或“sprintf("%.2f",除法结果)”语句进行四舍五入的处理值,并保留两位小数。

php怎么根据年月日判断是一年的第几天php怎么根据年月日判断是一年的第几天Apr 22, 2022 pm 05:02 PM

判断方法:1、使用“strtotime("年-月-日")”语句将给定的年月日转换为时间戳格式;2、用“date("z",时间戳)+1”语句计算指定时间戳是一年的第几天。date()返回的天数是从0开始计算的,因此真实天数需要在此基础上加1。

php怎么替换nbsp空格符php怎么替换nbsp空格符Apr 24, 2022 pm 02:55 PM

方法:1、用“str_replace(" ","其他字符",$str)”语句,可将nbsp符替换为其他字符;2、用“preg_replace("/(\s|\&nbsp\;||\xc2\xa0)/","其他字符",$str)”语句。

php怎么判断有没有小数点php怎么判断有没有小数点Apr 20, 2022 pm 08:12 PM

php判断有没有小数点的方法:1、使用“strpos(数字字符串,'.')”语法,如果返回小数点在字符串中第一次出现的位置,则有小数点;2、使用“strrpos(数字字符串,'.')”语句,如果返回小数点在字符串中最后一次出现的位置,则有。

php怎么设置implode没有分隔符php怎么设置implode没有分隔符Apr 18, 2022 pm 05:39 PM

在PHP中,可以利用implode()函数的第一个参数来设置没有分隔符,该函数的第一个参数用于规定数组元素之间放置的内容,默认是空字符串,也可将第一个参数设置为空,语法为“implode(数组)”或者“implode("",数组)”。

php怎么读取字符串后几个字符php怎么读取字符串后几个字符Apr 22, 2022 pm 08:31 PM

在php中,可以使用substr()函数来读取字符串后几个字符,只需要将该函数的第二个参数设置为负值,第三个参数省略即可;语法为“substr(字符串,-n)”,表示读取从字符串结尾处向前数第n个字符开始,直到字符串结尾的全部字符。

See all articles

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 agoBy尊渡假赌尊渡假赌尊渡假赌
Repo: How To Revive Teammates
4 weeks agoBy尊渡假赌尊渡假赌尊渡假赌
Hello Kitty Island Adventure: How To Get Giant Seeds
4 weeks agoBy尊渡假赌尊渡假赌尊渡假赌

Hot Tools

PhpStorm Mac version

PhpStorm Mac version

The latest (2018.2.1) professional PHP integrated development tool

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

mPDF

mPDF

mPDF is a PHP library that can generate PDF files from UTF-8 encoded HTML. The original author, Ian Back, wrote mPDF to output PDF files "on the fly" from his website and handle different languages. It is slower than original scripts like HTML2FPDF and produces larger files when using Unicode fonts, but supports CSS styles etc. and has a lot of enhancements. Supports almost all languages, including RTL (Arabic and Hebrew) and CJK (Chinese, Japanese and Korean). Supports nested block-level elements (such as P, DIV),

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

Safe Exam Browser

Safe Exam Browser

Safe Exam Browser is a secure browser environment for taking online exams securely. This software turns any computer into a secure workstation. It controls access to any utility and prevents students from using unauthorized resources.