<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta http-equiv="content-type" content="text/html; charset=UTF-8"> <title>Installation of extensions on Windows</title> </head> <body><div class="manualnavbar" style="text-align: center;"> <div class="prev" style="text-align: left; float: left;"><a href="install.windows.building.html">Building from source</a></div> <div class="next" style="text-align: right; float: right;"><a href="install.windows.commandline.html">Command Line PHP on Microsoft Windows</a></div> <div class="up"><a href="install.windows.html">Installation on Windows systems</a></div> <div class="home"><a href="index.html">PHP Manual</a></div> </div><hr /><div id="install.windows.extensions" class="sect1"> <h2 class="title">Installation of extensions on Windows</h2> <p class="para"> After installing PHP and a web server on Windows, you will probably want to install some extensions for added functionality. You can choose which extensions you would like to load when PHP starts by modifying your <var class="filename">php.ini</var>. You can also load a module dynamically in your script using <span class="function"><a href="function.dl.html" class="function">dl()</a></span>. </p> <p class="para"> The DLLs for PHP extensions are prefixed with <em>php_</em>. </p> <p class="para"> Many extensions are <em class="emphasis">built into</em> the Windows version of PHP. This means additional DLL files, and the <a href="ini.core.html#ini.extension" class="link">extension</a> directive, are <em class="emphasis">not</em> used to load these extensions. The Windows <a href="install.windows.extensions.html#install.windows.extensions.overview" class="link">PHP Extensions</a> table lists extensions that require, or used to require, additional PHP DLL files. Here's a list of built in extensions: </p> <p class="para"> In PHP 4 (updated PHP 4.3.11): <a href="book.bc.html" class="link">BCMath</a>, <a href="book.calendar.html" class="link">Caledar</a>, <a href="book.com.html" class="link">COM</a>, <a href="book.ctype.html" class="link">Ctype</a>, <a href="book.ftp.html" class="link">FTP</a>, <a href="book.mysql.html" class="link">MySQL</a>, <a href="book.uodbc.html" class="link">ODBC</a>, Overload, <a href="book.pcre.html" class="link">PCRE</a>, <a href="book.session.html" class="link">Session</a>, <a href="book.tokenizer.html" class="link">Tokenizer</a>, <a href="book.wddx.html" class="link">WDDX</a>, <a href="book.xml.html" class="link">XML</a> and <a href="book.zlib.html" class="link">Zlib</a> </p> <p class="para"> In PHP 5 (updated PHP 5.0.4), the following changes exist. Built in: <a href="book.dom.html" class="link">DOM</a>, <a href="book.libxml.html" class="link">LibXML</a>, <a href="book.iconv.html" class="link">Iconv</a>, <a href="book.simplexml.html" class="link">SimpleXML</a>, <a href="book.spl.html" class="link">SPL</a> and <a href="book.sqlite.html" class="link">SQLite</a>. And the following are no longer built in: <a href="book.mysql.html" class="link">MySQL</a> and Overload. </p> <p class="para"> The default location PHP searches for extensions is <var class="filename">C:\php4\extensions</var> in PHP 4 and <var class="filename">C:\php5</var> in PHP 5. To change this setting to reflect your setup of PHP edit your <var class="filename">php.ini</var> file: <ul class="itemizedlist"> <li class="listitem"> <p class="para"> You will need to change the <a href="ini.core.html#ini.extension-dir" class="link">extension_dir</a> setting to point to the directory where your extensions lives, or where you have placed your <var class="filename">php_*.dll</var> files. For example: <div class="informalexample"> <div class="example-contents"> <div class="inicode"><pre class="inicode">extension_dir = C:\php\extensions</pre> </div> </div> </div> </p> </li> <li class="listitem"> <p class="para"> Enable the extension(s) in <var class="filename">php.ini</var> you want to use by uncommenting the <em>extension=php_*.dll</em> lines in <var class="filename">php.ini</var>. This is done by deleting the leading ; from the extension you want to load. <div class="example" id="example-58"> <p><strong>Example #1 Enable <a href="book.bzip2.html" class="link">Bzip2</a> extension for PHP-Windows</strong></p> <div class="example-contents"> <div class="inicode"><pre class="inicode">// change the following line from ... ;extension=php_bz2.dll // ... to extension=php_bz2.dll</pre> </div> </div> </div> </p> </li> <li class="listitem"> <p class="para"> Some of the extensions need extra DLLs to work. Couple of them can be found in the distribution package, in the <var class="filename">C:\php\dlls\</var> folder in PHP 4 or in the main folder in PHP 5, but some, for example Oracle (<var class="filename">php_oci8.dll</var>) require DLLs which are not bundled with the distribution package. If you are installing PHP 4, copy the bundled DLLs from <var class="filename">C:\php\dlls</var> folder to the main <var class="filename">C:\php</var> folder. Don't forget to include <var class="filename">C:\php</var> in the system <var class="varname"><var class="varname">PATH</var></var> (this process is explained in a separate <a href="faq.installation.html#faq.installation.addtopath" class="link">FAQ entry</a>). </p> </li> <li class="listitem"> <p class="para"> Some of these DLLs are not bundled with the PHP distribution. See each extensions documentation page for details. Also, read the manual section titled <a href="install.pecl.html" class="link">Installation of PECL extensions</a> for details on <acronym title="PHP Extension and Application Repository">PECL</acronym>. An increasingly large number of PHP extensions are found in <acronym title="PHP Extension and Application Repository">PECL</acronym>, and these extensions require a <a href="install.pecl.downloads.html" class="link">separate download</a>. </p> </li> </ul> <blockquote class="note"><p><strong class="note">Note</strong>: <span class="simpara"> If you are running a server module version of PHP remember to restart your web server to reflect your changes to <var class="filename">php.ini</var>. </span> </p></blockquote> </p> <p class="para"> The following table describes some of the extensions available and required additional dlls. <table id="install.windows.extensions.overview" class="doctable table"> <caption><strong>PHP Extensions</strong></caption> <thead> <tr> <th>Extension</th> <th>Description</th> <th>Notes</th> </tr> </thead> <tbody class="tbody"> <tr> <td>php_bz2.dll</td> <td><a href="book.bzip2.html" class="link">bzip2</a> compression functions</td> <td>None</td> </tr> <tr> <td>php_calendar.dll</td> <td><a href="book.calendar.html" class="link">Calendar</a> conversion functions</td> <td>Built in since PHP 4.0.3</td> </tr> <tr> <td>php_crack.dll</td> <td><a href="book.crack.html" class="link">Crack</a> functions</td> <td>None</td> </tr> <tr> <td>php_ctype.dll</td> <td><a href="book.ctype.html" class="link">ctype</a> family functions</td> <td>Built in since PHP 4.3.0</td> </tr> <tr> <td>php_curl.dll</td> <td><a href="book.curl.html" class="link">CURL</a>, Client URL library functions</td> <td>Requires: <var class="filename">libeay32.dll</var>, <var class="filename">ssleay32.dll</var> (bundled)</td> </tr> <tr> <td>php_dba.dll</td> <td><a href="book.dba.html" class="link">DBA</a>: DataBase (dbm-style) Abstraction layer functions</td> <td>None</td> </tr> <tr> <td>php_dbase.dll</td> <td><a href="book.dbase.html" class="link">dBase</a> functions</td> <td>None</td> </tr> <tr> <td>php_dbx.dll</td> <td><a href="book.dbx.html" class="link">dbx</a> functions</td> <td class="empty"> </td> </tr> <tr> <td>php_domxml.dll</td> <td>PHP 4 domxml functions</td> <td> PHP <= 4.2.0 requires: <var class="filename">libxml2.dll</var> (bundled) PHP >= 4.3.0 requires: <var class="filename">iconv.dll</var> (bundled) </td> </tr> <tr> <td>php_dotnet.dll</td> <td><a href="book.dotnet.html" class="link">.NET</a> functions</td> <td>PHP <= 4.1.1</td> </tr> <tr> <td>php_exif.dll</td> <td><a href="book.exif.html" class="link">EXIF</a> functions</td> <td> <a href="book.mbstring.html" class="link">php_mbstring.dll</a>. And, <var class="filename">php_exif.dll</var> must be loaded <em>after</em> <var class="filename">php_mbstring.dll</var> in <var class="filename">php.ini</var>. </td> </tr> <tr> <td>php_fbsql.dll</td> <td><a href="book.fbsql.html" class="link">FrontBase</a> functions</td> <td>PHP <= 4.2.0</td> </tr> <tr> <td>php_fdf.dll</td> <td><a href="book.fdf.html" class="link">FDF</a>: Forms Data Format functions.</td> <td>Requires: <var class="filename">fdftk.dll</var> (bundled)</td> </tr> <tr> <td>php_filepro.dll</td> <td><a href="book.filepro.html" class="link">filePro</a> functions</td> <td>Read-only access</td> </tr> <tr> <td>php_ftp.dll</td> <td><a href="book.ftp.html" class="link">FTP</a> functions</td> <td>Built-in since PHP 4.0.3</td> </tr> <tr> <td>php_gd.dll</td> <td><a href="book.image.html" class="link">GD</a> library image functions</td> <td> Removed in PHP 4.3.2. Also note that truecolor functions are not available in GD1, instead, use <var class="filename">php_gd2.dll</var>. </td> </tr> <tr> <td>php_gd2.dll</td> <td><a href="book.image.html" class="link">GD</a> library image functions</td> <td>GD2</td> </tr> <tr> <td>php_gettext.dll</td> <td><a href="book.gettext.html" class="link">Gettext</a> functions</td> <td> PHP <= 4.2.0 requires <var class="filename">gnu_gettext.dll</var> (bundled), PHP >= 4.2.3 requires <var class="filename">libintl-1.dll</var>, <var class="filename">iconv.dll</var> (bundled). </td> </tr> <tr> <td>php_hyperwave.dll</td> <td><a href="book.hw.html" class="link">HyperWave</a> functions</td> <td>None</td> </tr> <tr> <td>php_iconv.dll</td> <td><a href="book.iconv.html" class="link">ICONV</a> characterset conversion</td> <td>Requires: <var class="filename">iconv-1.3.dll</var> (bundled), PHP >=4.2.1 <var class="filename">iconv.dll</var></td> </tr> <tr> <td>php_ifx.dll</td> <td><a href="book.ifx.html" class="link">Informix</a> functions</td> <td>Requires: Informix libraries</td> </tr> <tr> <td>php_iisfunc.dll</td> <td>IIS management functions</td> <td>None</td> </tr> <tr> <td>php_imap.dll</td> <td><a href="book.imap.html" class="link">IMAP</a> POP3 and NNTP functions</td> <td>None</td> </tr> <tr> <td>php_ingres.dll</td> <td><a href="book.ingres.html" class="link">Ingres</a> functions</td> <td>Requires: Ingres libraries</td> </tr> <tr> <td>php_interbase.dll</td> <td><a href="book.ibase.html" class="link">InterBase</a> functions</td> <td>Requires: <var class="filename">gds32.dll</var> (bundled)</td> </tr> <tr> <td>php_java.dll</td> <td><a href="book.java.html" class="link">Java</a> functions</td> <td>PHP <= 4.0.6 requires: <var class="filename">jvm.dll</var> (bundled)</td> </tr> <tr> <td>php_ldap.dll</td> <td><a href="book.ldap.html" class="link">LDAP</a> functions</td> <td> PHP <= 4.2.0 requires <var class="filename">libsasl.dll</var> (bundled), PHP >= 4.3.0 requires <var class="filename">libeay32.dll</var>, <var class="filename">ssleay32.dll</var> (bundled) </td> </tr> <tr> <td>php_mbstring.dll</td> <td><a href="book.mbstring.html" class="link">Multi-Byte String</a> functions</td> <td>None</td> </tr> <tr> <td>php_mcrypt.dll</td> <td><a href="book.mcrypt.html" class="link">Mcrypt Encryption</a> functions</td> <td>Requires: <var class="filename">libmcrypt.dll</var></td> </tr> <tr> <td>php_mhash.dll</td> <td><a href="book.mhash.html" class="link">Mhash</a> functions</td> <td>PHP >= 4.3.0 requires: <var class="filename">libmhash.dll</var> (bundled)</td> </tr> <tr> <td>php_mime_magic.dll</td> <td><a href="book.mime-magic.html" class="link">Mimetype</a> functions</td> <td>Requires: <var class="filename">magic.mime</var> (bundled)</td> </tr> <tr> <td>php_ming.dll</td> <td><a href="book.ming.html" class="link">Ming</a> functions for Flash</td> <td>None</td> </tr> <tr> <td>php_msql.dll</td> <td><a href="book.msql.html" class="link">mSQL</a> functions</td> <td>Requires: <var class="filename">msql.dll</var> (bundled)</td> </tr> <tr> <td>php_mssql.dll</td> <td><a href="book.mssql.html" class="link">MSSQL</a> functions</td> <td>Requires: <var class="filename">ntwdblib.dll</var> (bundled)</td> </tr> <tr> <td>php_mysql.dll</td> <td><a href="book.mysql.html" class="link">MySQL</a> functions</td> <td>PHP >= 5.0.0, requires <var class="filename">libmysql.dll</var> (bundled)</td> </tr> <tr> <td>php_mysqli.dll</td> <td><a href="book.mysqli.html" class="link">MySQLi</a> functions</td> <td>PHP >= 5.0.0, requires <var class="filename">libmysql.dll</var> (<var class="filename">libmysqli.dll</var> in PHP <= 5.0.2) (bundled)</td> </tr> <tr> <td>php_oci8.dll</td> <td><a href="book.oci8.html" class="link">Oracle 8</a> functions</td> <td>Requires: Oracle 8.1+ client libraries</td> </tr> <tr> <td>php_openssl.dll</td> <td><a href="book.openssl.html" class="link">OpenSSL</a> functions</td> <td>Requires: <var class="filename">libeay32.dll</var> (bundled)</td> </tr> <tr> <td>php_overload.dll</td> <td>PHP 4 Object overloading functions</td> <td>Built in since PHP 4.3.0, removed as of PHP 5.0.0</td> </tr> <tr> <td>php_pdf.dll</td> <td><a href="book.pdf.html" class="link">PDF</a> functions</td> <td>None</td> </tr> <tr> <td>php_pgsql.dll</td> <td><a href="book.pgsql.html" class="link">PostgreSQL</a> functions</td> <td>None</td> </tr> <tr> <td>php_printer.dll</td> <td><a href="book.printer.html" class="link">Printer</a> functions</td> <td>None</td> </tr> <tr> <td>php_shmop.dll</td> <td><a href="book.shmop.html" class="link">Shared Memory</a> functions</td> <td>None</td> </tr> <tr> <td>php_snmp.dll</td> <td><a href="book.snmp.html" class="link">SNMP</a> get and walk functions</td> <td>NT only!</td> </tr> <tr> <td>php_soap.dll</td> <td><a href="book.soap.html" class="link">SOAP</a> functions</td> <td>PHP >= 5.0.0</td> </tr> <tr> <td>php_sockets.dll</td> <td><a href="book.sockets.html" class="link">Socket</a> functions</td> <td>None</td> </tr> <tr> <td>php_sybase_ct.dll</td> <td><a href="book.sybase.html" class="link">Sybase</a> functions</td> <td>Requires: Sybase client libraries</td> </tr> <tr> <td>php_tidy.dll</td> <td><a href="book.tidy.html" class="link">Tidy</a> functions</td> <td>PHP >= 5.0.0</td> </tr> <tr> <td>php_tokenizer.dll</td> <td><a href="book.tokenizer.html" class="link">Tokenizer</a> functions</td> <td>Built in since PHP 4.3.0</td> </tr> <tr> <td>php_w32api.dll</td> <td><a href="book.w32api.html" class="link">W32api</a> functions</td> <td>None</td> </tr> <tr> <td>php_xmlrpc.dll</td> <td><a href="book.xmlrpc.html" class="link">XML-RPC</a> functions</td> <td>PHP >= 4.2.1 requires: <var class="filename">iconv.dll</var> (bundled)</td> </tr> <tr> <td>php_xslt.dll</td> <td><a href="book.xslt.html" class="link">XSLT</a> functions</td> <td> PHP <= 4.2.0 requires <var class="filename">sablot.dll</var>, <var class="filename">expat.dll</var> (bundled). PHP >= 4.2.1 requires <var class="filename">sablot.dll</var>, <var class="filename">expat.dll</var>, <var class="filename">iconv.dll</var> (bundled). </td> </tr> <tr> <td>php_yaz.dll</td> <td><a href="book.yaz.html" class="link">YAZ</a> functions</td> <td>Requires: <var class="filename">yaz.dll</var> (bundled)</td> </tr> <tr> <td>php_zip.dll</td> <td><a href="book.zip.html" class="link">Zip File</a> functions</td> <td>Read only access</td> </tr> <tr> <td>php_zlib.dll</td> <td><a href="book.zlib.html" class="link">ZLib</a> compression functions</td> <td>Built in since PHP 4.3.0</td> </tr> </tbody> </table> </p> </div><hr /><div class="manualnavbar" style="text-align: center;"> <div class="prev" style="text-align: left; float: left;"><a href="install.windows.building.html">Building from source</a></div> <div class="next" style="text-align: right; float: right;"><a href="install.windows.commandline.html">Command Line PHP on Microsoft Windows</a></div> <div class="up"><a href="install.windows.html">Installation on Windows systems</a></div> <div class="home"><a href="index.html">PHP Manual</a></div> </div></body></html>