Home >Backend Development >PHP Tutorial >Master's Guide to PHP Installation and Configuration_PHP Tutorial
With the rapid development of PHP, its functions are becoming more and more powerful, and it has become very convenient to use it. Let’s introduce the installation and configuration of PHP5 in detail. The execution efficiency of PHP is obvious to all, which is one of the reasons why I like it. If you want to integrate it with Mysql and Apache, which are called its excellent partners, you can't help but marvel at its efficiency.
PHP installation configuration
1. Unzip the PHP compressed package to C:PHP (this path can be arbitrary, but if this path is used below, please modify it accordingly ).
2. Copy php4ts.dll in the C:PHP directory and all files in the C:PHPdlls directory to the Windows system folder. The folder varies depending on the Windows version
◆If so For Windows 9x/ME, it is c:windowssystem
◆If it is Windows NT/2000, it is c:winntsystem32
◆If it is Windows XP/server2003, it is c:windowssystem32
where C: is you The system disk of the operating system you are currently using. If your current operating system is not installed under C:windows, please modify it accordingly. Copy php.ini-dist to C:windows (XP/2003/9x/Me) or C:Winnt (2000/nt) and rename it to php.ini. Open it with Notepad and modify the information: search for the line extension_dir = ./ and point its path to the extensions directory in your PHP directory, such as:
<ol class="dp-xml"><li class="alt"><span><span class="attribute"><font color="#ff0000">extension_dir</font></span><span> = </span><span class="attribute-value"><font color="#0000ff">C</font></span><span>:PHPextensions </span></span></li></ol>
If you want to support more modules, Please proceed below. If you don’t want to, just save the php.ini file directly. PHP supports many modules, but some dlls are not free, so they are not released with the PHP compressed package. However, the ones in the dlls folder are very More, we have just copied them to the system32 folder, now we test to see how many modules it supports. The following are the results of my test, for reference only. If after the installation is completed, it pops up that the xxx.dll module is not supported, just add the semicolon in front of it. Search:
<ol class="dp-xml"> <li class="alt"><span><span>Windows Extensions </span></span></li> <li class=""><span>Note that MySQL and ODBC support is now built in, so no dll is needed for it. </span></li> </ol>
Use both below The semicolon comments out the supported extension modules in front. If you want PHP to support a certain module, please remove the ";" in front. The following are the results after my test. Generally, there will be no problem after removing the comments as follows. :
<ol class="dp-xml"> <li class="alt"><span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_bz2</span><span>.dll </span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_cpdf</span><span>.dll </span></span></li> <li class="alt"><span><span></span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_crack</span><span>.dll </span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_curl</span><span>.dll </span></span></li> <li class="alt"><span><span></span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_db</span><span>.dll </span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_dba</span><span>.dll </span></span></li> <li class="alt"><span><span></span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_dbase</span><span>.dll </span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_dbx</span><span>.dll </span></span></li> <li class="alt"><span><span></span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_domxml</span><span>.dll </span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_exif</span><span>.dll </span></span></li> <li class="alt"><span><span></span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_fdf</span><span>.dll </span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_filepro</span><span>.dll </span></span></li> <li class="alt"><span><span></span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_gd2</span><span>.dll </span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_gettext</span><span>.dll </span></span></li> <li class="alt"><span><span></span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_hyperwave</span><span>.dll </span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_iconv</span><span>.dll ;</span></span></li> <li class="alt"><span><span></span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_ifx</span><span>.dll ;</span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_iisfunc</span><span>.dll </span></span></li> <li class="alt"><span><span></span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_imap</span><span>.dll </span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_interbase</span><span>.dll </span></span></li> <li class="alt"><span><span></span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_java</span><span>.dll </span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_ldap</span><span>.dll </span></span></li> <li class="alt"><span><span></span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_mbstring</span><span>.dll ;</span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_mcrypt</span><span>.dll </span></span></li> <li class="alt"><span><span></span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_mhash</span><span>.dll </span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_mime_magic</span><span>.dll </span></span></li> <li class="alt"><span><span></span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_ming</span><span>.dll </span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_mssql</span><span>.dll </span></span></li> <li class="alt"><span><span></span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_msql</span><span>.dll ;</span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_oci8</span><span>.dll </span></span></li> <li class="alt"><span><span></span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_openssl</span><span>.dll ;</span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_oracle</span><span>.dll </span></span></li> <li class="alt"><span><span></span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_pdf</span><span>.dll </span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_pgsql</span><span>.dll ;</span></span></li> <li class="alt"><span><span></span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_printer</span><span>.dll </span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_shmop</span><span>.dll </span></span></li> <li class="alt"><span><span></span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_snmp</span><span>.dll </span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_sockets</span><span>.dll ;</span></span></li> <li class="alt"><span><span></span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_sybase_ct</span><span>.dll </span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_w32api</span><span>.dll </span></span></li> <li class="alt"><span><span></span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_xmlrpc</span><span>.dll </span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_xslt</span><span>.dll </span></span></li> <li class="alt"><span><span></span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_yaz</span><span>.dll </span><span class="attribute">extension</span><span>=</span><span class="attribute-value">php_zip</span><span>.dll </span></span></li> </ol>
After the modification is completed, save php.ini. This completes the installation and configuration of PHP.