fix xml:id for methods, document webPhar, add xml:id to all <section>

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@251096 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
Greg Beaver 2008-01-21 21:54:18 +00:00
parent d397e937f9
commit f45d3cb110
63 changed files with 242 additions and 183 deletions

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.apiVersion">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.apiversion">
<refnamediv>
<refname>Phar::apiVersion</refname>
<refpurpose>Returns the api version</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="Phar.buildFromIterator" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- $Revision: 1.2 $ -->
<refentry xml:id="phar.buildfromiterator" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>Phar::buildFromIterator</refname>
<refpurpose>Construct a phar archive from an iterator.</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.canCompress">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.cancompress">
<refnamediv>
<refname>Phar::canCompress</refname>
<refpurpose>Returns whether phar extension supports compression using either zlib or bzip2</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.canWrite">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.canwrite">
<refnamediv>
<refname>Phar::canWrite</refname>
<refpurpose>Returns whether phar extension supports writing and creating phars</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.compressAllFilesBZIP2">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.compressallfilesbzip2">
<refnamediv>
<refname>Phar::compressAllFilesBZIP2</refname>
<refpurpose>Compresses all files in the current Phar archive using Bzip2 compression</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.compressAllFilesGZ">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.compressallfilesgz">
<refnamediv>
<refname>Phar::compressAllFilesGZ</refname>
<refpurpose>Compresses all files in the current Phar archive using Gzip compression</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns:xlink="http://www.w3.org/1999/xlink" xmlns="http://docbook.org/ns/docbook" xml:id="Phar.--construct">
<!-- $Revision: 1.2 $ -->
<refentry xmlns:xlink="http://www.w3.org/1999/xlink" xmlns="http://docbook.org/ns/docbook" xml:id="phar.--construct">
<refnamediv>
<refname>Phar::__construct</refname>
<refpurpose>Construct a Phar archive object</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="Phar.convertToPhar" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- $Revision: 1.2 $ -->
<refentry xml:id="phar.converttophar" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>Phar::convertToPhar</refname>
<refpurpose>Convert the phar archive to the phar file format, optionally compressing the entire archive using gzip or bzip2 compression</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="Phar.convertToTar" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- $Revision: 1.2 $ -->
<refentry xml:id="phar.converttotar" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>Phar::convertToTar</refname>
<refpurpose>Convert the phar archive to the tar file format, optionally compressing the entire archive using gzip or bzip2 compression</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="Phar.convertToZip" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- $Revision: 1.2 $ -->
<refentry xml:id="phar.converttozip" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>Phar::convertToZip</refname>
<refpurpose>Convert the phar archive to the zip file format</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="Phar.copy" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- $Revision: 1.2 $ -->
<refentry xml:id="phar.copy" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>Phar::copy</refname>
<refpurpose>Copy a file internal to the phar archive to another new file within the phar</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.count">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.count">
<refnamediv>
<refname>Phar::count</refname>
<refpurpose>Returns the number of entries (files) in the Phar archive</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.createDefaultStub">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.createdefaultstub">
<refnamediv>
<refname>Phar::createDefaultStub</refname>
<refpurpose>Return the PHP loader or bootstrap stub of a Phar archive</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="Phar.delMetadata" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- $Revision: 1.2 $ -->
<refentry xml:id="phar.delmetadata" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>Phar::delMetadata</refname>
<refpurpose>Deletes the global metadata of the phar</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.getMetadata">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.getmetadata">
<refnamediv>
<refname>Phar::getMetaData</refname>
<refpurpose>Returns phar archive meta-data</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.getModified">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.getmodified">
<refnamediv>
<refname>Phar::getModified</refname>
<refpurpose>Return whether phar was modified</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.getSignature">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.getsignature">
<refnamediv>
<refname>Phar::getSignature</refname>
<refpurpose>Return MD5/SHA1/SHA256/SHA512 signature of a Phar archive</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.getStub">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.getstub">
<refnamediv>
<refname>Phar::getStub</refname>
<refpurpose>Return the PHP loader or bootstrap stub of a Phar archive</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="Phar.getSupportedCompression" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- $Revision: 1.2 $ -->
<refentry xml:id="phar.getsupportedcompression" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>Phar::getSupportedCompression</refname>
<refpurpose>Return array of supported compression algorithms</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="Phar.getSupportedSignatures" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- $Revision: 1.2 $ -->
<refentry xml:id="phar.getsupportedsignatures" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>Phar::getSupportedSignatures</refname>
<refpurpose>Return array of supported signature types</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.getVersion">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.getversion">
<refnamediv>
<refname>Phar::getVersion</refname>
<refpurpose>Return version info of Phar archive</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="Phar.hasMetadata" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- $Revision: 1.2 $ -->
<refentry xml:id="phar.hasmetadata" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>Phar::hasMetaData</refname>
<refpurpose>Returns whether phar has global meta-data</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="Phar.interceptFileFuncs" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- $Revision: 1.2 $ -->
<refentry xml:id="phar.interceptfilefuncs" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>Phar::interceptFileFuncs</refname>
<refpurpose>instructs phar to intercept fopen, file_get_contents, opendir, and all of the stat-related functions</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.isBuffering">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.isbuffering">
<refnamediv>
<refname>Phar::isBuffering</refname>
<refpurpose>Used to determine whether Phar write operations are being buffered, or are flushing directly to disk</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="Phar.isCompressed" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- $Revision: 1.2 $ -->
<refentry xml:id="phar.iscompressed" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>Phar::isCompressed</refname>
<refpurpose>Returns Phar::GZ or PHAR::BZ2 if the entire phar archive is compressed (.tar.gz/tar.bz and so on)</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="Phar.isPhar" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- $Revision: 1.2 $ -->
<refentry xml:id="phar.isphar" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>Phar::isPhar</refname>
<refpurpose>Returns true if the phar archive is based on the phar file format</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="Phar.isTar" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- $Revision: 1.2 $ -->
<refentry xml:id="phar.istar" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>Phar::isTar</refname>
<refpurpose>Returns true if the phar archive is based on the tar file format</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="Phar.isValidPharFilename" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- $Revision: 1.2 $ -->
<refentry xml:id="phar.isvalidpharfilename" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>Phar::isValidPharFilename</refname>
<refpurpose>Returns whether the given filename is a valid phar filename</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="Phar.isZip" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- $Revision: 1.2 $ -->
<refentry xml:id="phar.iszip" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>Phar::isZip</refname>
<refpurpose>Returns true if the phar archive is based on the Zip file format</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.loadPhar">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.loadphar">
<refnamediv>
<refname>Phar::loadPhar</refname>
<refpurpose>Loads any phar archive with an alias</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.mapPhar">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.mapphar">
<refnamediv>
<refname>Phar::mapPhar</refname>
<refpurpose>Reads the currently executed file (a phar) and registers its manifest</refpurpose>
@ -28,7 +28,8 @@
<term><parameter>alias</parameter></term>
<listitem>
<para>
The alias with which this phar should be referred to.
The alias that can be used in <literal>phar://</literal> URLs to
refer to this archive, rather than its full path.
</para>
</listitem>
</varlistentry>
@ -36,6 +37,7 @@
<term><parameter>dataoffset</parameter></term>
<listitem>
<para>
Unused variable, here for compatibility with PEAR's PHP_Archive.
</para>
</listitem>
</varlistentry>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="Phar.mungServer" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- $Revision: 1.2 $ -->
<refentry xml:id="phar.mungserver" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>Phar::mungServer</refname>
<refpurpose>Defines a list of up to 4 $_SERVER variables that should be modified for execution</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.offsetExists">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.offsetexists">
<refnamediv>
<refname>Phar::offsetExists</refname>
<refpurpose>determines whether a file exists in the phar</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.offsetGet">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.offsetget">
<refnamediv>
<refname>Phar::offsetGet</refname>
<refpurpose>get a PharFileInfo object for a specific file</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.offsetSet">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.offsetset">
<refnamediv>
<refname>Phar::offsetSet</refname>
<refpurpose>set the contents of an internal file to those of an external file</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.offsetUnset">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.offsetunset">
<refnamediv>
<refname>Phar::offsetUnset</refname>
<refpurpose>remove a file from a phar</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="Phar.setAlias" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- $Revision: 1.2 $ -->
<refentry xml:id="phar.setalias" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>Phar::setAlias</refname>
<refpurpose>Set the alias for the Phar archive</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns:xlink="http://www.w3.org/1999/xlink" xmlns="http://docbook.org/ns/docbook" xml:id="Phar.setMetadata">
<!-- $Revision: 1.2 $ -->
<refentry xmlns:xlink="http://www.w3.org/1999/xlink" xmlns="http://docbook.org/ns/docbook" xml:id="phar.setmetadata">
<refnamediv>
<refname>Phar::setMetadata</refname>
<refpurpose>Sets phar archive meta-data</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="Phar.setSignatureAlgorithm" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- $Revision: 1.2 $ -->
<refentry xml:id="phar.setsignaturealgorithm" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>Phar::setSignatureAlgorithm</refname>
<refpurpose>set the signature algorithm for a phar and apply it. The</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.setStub">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.setstub">
<refnamediv>
<refname>Phar::setStub</refname>
<refpurpose>Used to set the PHP loader or bootstrap stub of a Phar archive</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.startBuffering">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.startbuffering">
<refnamediv>
<refname>Phar::startBuffering</refname>
<refpurpose>Start buffering Phar write operations, do not modify the Phar object on disk</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.stopBuffering">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.stopbuffering">
<refnamediv>
<refname>Phar::stopBuffering</refname>
<refpurpose>Stop buffering write requests to the Phar archive, and save changes to disk</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="Phar.uncompressAllFiles">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phar.uncompressallfiles">
<refnamediv>
<refname>Phar::uncompressAllFiles</refname>
<refpurpose>Uncompresses all files in the current Phar archive</refpurpose>

View file

@ -1,9 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="Phar.webPhar" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- $Revision: 1.2 $ -->
<refentry xml:id="phar.webphar" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>Phar::webPhar</refname>
<refpurpose>mapPhar for web-based phars. Reads the currently executed file (a phar)</refpurpose>
<refpurpose>mapPhar for web-based phars. front controller for web applications</refpurpose>
</refnamediv>
<refsect1 role="description">
@ -16,9 +16,20 @@
<methodparam><type>array</type><parameter>mimetypes</parameter></methodparam>
<methodparam><type>array</type><parameter>rewrites</parameter></methodparam>
</methodsynopsis>
&warn.undocumented.func;
<para>
mapPhar for web-based phars. Reads the currently executed file (a phar)
<function>Phar::mapPhar</function> for web-based phars. This method parses
<literal>$_SERVER['REQUEST_URI']</literal> and routes a request from a web
browser to an internal file within the phar archive. In essence, it simulates
a web server, routing requests to the correct file, echoing the correct headers
and parsing PHP files as needed. This powerful method is part of what makes it easy
to convert an existing PHP application into a phar archive. Combined with
<function>Phar::mungServer</function> and <function>Phar::interceptFileFuncs</function>,
any web application can be used unmodified from a phar archive.
</para>
<para>
<function>Phar::webPhar</function> should only be
called from the stub of a phar archive (see <link linkend="phar.fileformat.stub">here</link>
for more information on what a stub is).
</para>
</refsect1>
@ -30,6 +41,8 @@
<term><parameter>alias</parameter></term>
<listitem>
<para>
The alias that can be used in <literal>phar://</literal> URLs to
refer to this archive, rather than its full path.
</para>
</listitem>
</varlistentry>
@ -37,6 +50,8 @@
<term><parameter>index</parameter></term>
<listitem>
<para>
The location within the phar of the directory index, defaults to
<literal>index.php</literal>.
</para>
</listitem>
</varlistentry>
@ -44,6 +59,8 @@
<term><parameter>f404</parameter></term>
<listitem>
<para>
The location of the script to run when a file is not found. This
script should output the proper HTTP 404 headers.
</para>
</listitem>
</varlistentry>
@ -51,6 +68,54 @@
<term><parameter>mimetypes</parameter></term>
<listitem>
<para>
An array mapping additional file extensions to MIME type. By default,
these extensions are mapped to these mime types:
<programlisting role="php">
<![CDATA[
$mimes = array(
'phps' => 2, // pass to highlight_file()
'c' => 'text/plain',
'cc' => 'text/plain',
'cpp' => 'text/plain',
'c++' => 'text/plain',
'dtd' => 'text/plain',
'h' => 'text/plain',
'log' => 'text/plain',
'rng' => 'text/plain',
'txt' => 'text/plain',
'xsd' => 'text/plain',
'php' => 1, // parse as PHP
'inc' => 1, // parse as PHP
'avi' => 'video/avi',
'bmp' => 'image/bmp',
'css' => 'text/css',
'gif' => 'image/gif',
'htm' => 'text/html',
'html' => 'text/html',
'htmls' => 'text/html',
'ico' => 'image/x-ico',
'jpe' => 'image/jpeg',
'jpg' => 'image/jpeg',
'jpeg' => 'image/jpeg',
'js' => 'application/x-javascript',
'midi' => 'audio/midi',
'mid' => 'audio/midi',
'mod' => 'audio/mod',
'mov' => 'movie/quicktime',
'mp3' => 'audio/mp3',
'mpg' => 'video/mpeg',
'mpeg' => 'video/mpeg',
'pdf' => 'application/pdf',
'png' => 'image/png',
'swf' => 'application/shockwave-flash',
'tif' => 'image/tiff',
'tiff' => 'image/tiff',
'wav' => 'audio/wav',
'xbm' => 'image/xbm',
'xml' => 'text/xml',
);
]]>
</programlisting>
</para>
</listitem>
</varlistentry>
@ -58,6 +123,19 @@
<term><parameter>rewrites</parameter></term>
<listitem>
<para>
An array mapping URI to internal file, simulating mod_rewrite of apache.
For example:
<programlisting role="php">
<![CDATA[
array(
'myinfo' => 'myinfo.php'
);
]]>
</programlisting>
would route calls to <literal>http://&lt;host&gt;/myphar.phar/myinfo</literal>
to the file <literal>phar:///path/to/myphar.phar/myinfo.php</literal>, preserving
GET/POST. This does not quite work like mod_rewrite in that it would not
match <literal>http://&lt;host&gt;/myphar.phar/myinfo/another</literal>.
</para>
</listitem>
</varlistentry>
@ -68,84 +146,63 @@
<refsect1 role="returnvalues">
&reftitle.returnvalues;
<para>
No return values
</para>
</refsect1>
<!-- Use when ERRORS exist
<refsect1 role="errors">
&reftitle.errors;
<para>
When does this function throw E_* level errors, or exceptions?
Throws <classname>PharException</classname> when unable to open the internal
file to output, if <function>Phar::webPhar</function> is used from within
an <link linkend="ini.phar.extract-list">extracted Phar archive</link>, or if
called from a non-stub. If an invalid array value is passed into
<parameter>mimetypes</parameter> or to <parameter>rewrites</parameter>, then
<classname>UnexpectedValueException</classname> is thrown.
</para>
</refsect1>
-->
<!-- Use when a CHANGELOG exists
<refsect1 role="changelog">
&reftitle.changelog;
<para>
<informaltable>
<tgroup cols="2">
<thead>
<row>
<entry>&Version;</entry>
<entry>&Description;</entry>
</row>
</thead>
<tbody>
<row>
<entry>Enter the PHP version of change here</entry>
<entry>Description of change</entry>
</row>
</tbody>
</tgroup>
</informaltable>
</para>
</refsect1>
-->
<!-- Use when examples exist
<refsect1 role="examples">
&reftitle.examples;
<para>
<example>
<title>A <function>Phar::webPhar</function> example</title>
<para>
Any text that describes the purpose of the example, or
what goes on in the example should go here (inside the
<example> tag, not out
With the example below, the created phar will display <literal>Hello World</literal>
if one browses to <literal>/myphar.phar/index.php</literal> or to
<literal>/myphar.phar</literal>, and will display the source of
<literal>index.phps</literal> if one browses to <literal>/myphar.phar/index.phps</literal>.
</para>
<programlisting role="php">
<![CDATA[
<?php
if ($anexample === true) {
echo 'Use the PEAR Coding Standards';
// creating the phar archive:
try {
$phar = new Phar('myphar.phar');
$phar['index.php'] = '<?php echo "Hello World"; ?>';
$phar['index.phps'] = '<?php echo "Hello World"; ?>';
$phar->setStub('<?php
Phar::webPhar();
__HALT_COMPILER(); ?>');
} catch (Exception $e) {
// handle error here
}
?>
]]>
</programlisting>
&example.outputs;
<screen>
<![CDATA[
Use the PEAR Coding Standards
]]>
</screen>
</example>
</para>
</refsect1>
-->
<!-- Use when adding See Also links
<refsect1 role="seealso">
&reftitle.seealso;
<para>
<simplelist>
<member><function></function></member>
<member>Or <link linkend="somethingelse">something else</link></member>
<member><function>Phar::mungServer</function></member>
<member><function>Phar::interceptFileFuncs</function></member>
</simplelist>
</para>
</refsect1>
-->
</refentry>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="PharFileInfo.chmod">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phargileinfo.chmod">
<refnamediv>
<refname>PharFileInfo::chmod</refname>
<refpurpose>Sets file-specific permission bits</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="PharFileInfo.--construct">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="pharfileinfo.--construct">
<refnamediv>
<refname>PharFileInfo::__construct</refname>
<refpurpose>Construct a Phar entry object</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="PharFileInfo.delMetadata" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- $Revision: 1.2 $ -->
<refentry xml:id="phargileinfo.delmetadata" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>PharFileInfo::delMetadata</refname>
<refpurpose>Deletes the metadata of the entry</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="PharFileInfo.getCRC32">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="pharfileinfo.getcrc32">
<refnamediv>
<refname>PharFileInfo::getCRC32</refname>
<refpurpose>Returns CRC32 code or throws an exception if CRC has not been verified</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="PharFileInfo.getCompressedSize">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="pharfileinfo.getcompressedsize">
<refnamediv>
<refname>PharFileInfo::getCompressedSize</refname>
<refpurpose>Returns the actual size of the file (with compression) inside the Phar archive</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="PharFileInfo.getmetadata">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="pharfileinfo.getmetadata">
<refnamediv>
<refname>PharFileInfo::getMetaData</refname>
<refpurpose>Returns file-specific meta-data saved with a file</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="PharFileInfo.getPharFlags">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="pharfileinfo.getpharflags">
<refnamediv>
<refname>PharFileInfo::getPharFlags</refname>
<refpurpose>Returns the Phar file entry flags</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="PharFileInfo.hasMetadata" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- $Revision: 1.2 $ -->
<refentry xml:id="pharfileinfo.hasmetadata" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>PharFileInfo::hasMetadata</refname>
<refpurpose>Returns the metadata of the entry</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="PharFileInfo.isCRCChecked">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="pharfileinfo.iscrcchecked">
<refnamediv>
<refname>PharFileInfo::isCRCChecked</refname>
<refpurpose>Returns whether file entry has had its CRC verified</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="PharFileInfo.isCompressed">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="pharfileinfo.iscompressed">
<refnamediv>
<refname>PharFileInfo::isCompressed</refname>
<refpurpose>Returns whether the entry is compressed</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="PharFileInfo.isCompressedBZIP2">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="pharfileinfo.iscompressedbzip2">
<refnamediv>
<refname>PharFileInfo::isCompressedBZIP2</refname>
<refpurpose>Returns whether the entry is compressed using bzip2</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="PharFileInfo.isCompressedGZ">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="pharfileinfo.iscompressedgz">
<refnamediv>
<refname>PharFileInfo::isCompressedGZ</refname>
<refpurpose>Returns whether the entry is compressed using gz</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="PharFileInfo.setCompressedBZIP2">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="pharfileinfo.setcompressedbzip2">
<refnamediv>
<refname>PharFileInfo::setCompressedBZIP2</refname>
<refpurpose>Compresses the current Phar entry within the phar using Bzip2 compression</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="PharFileInfo.setCompressedGZ">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="pharfileinfo.setcompressedgz">
<refnamediv>
<refname>PharFileInfo::setCompressedGZ</refname>
<refpurpose>Compresses the current Phar entry within the phar using gz compression</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="PharFileInfo.setMetadata">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="pharfileinfo.setmetadata">
<refnamediv>
<refname>PharFileInfo::setMetaData</refname>
<refpurpose>Sets file-specific meta-data saved with a file</refpurpose>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="PharFileInfo.setUncompressed">
<!-- $Revision: 1.2 $ -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="pharfileinfo.setuncompressed">
<refnamediv>
<refname>PharFileInfo::setUncompressed</refname>
<refpurpose>Uncompresses the current Phar entry within the phar, if it is compressed</refpurpose>

View file

@ -1,9 +1,9 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.1 $ -->
<!-- $Revision: 1.2 $ -->
<chapter xml:id="phar.creating" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<title>Creating Phar Archives</title>
<section>
<section xml:id="phar.creating.intro" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<title>Creating Phar Archives: Introduction</title>
<para>
To be written fully in the near future. Before reading this, be sure to read

View file

@ -1,8 +1,8 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.8 $ -->
<!-- $Revision: 1.9 $ -->
<chapter xml:id="phar.fileformat" xmlns="http://docbook.org/ns/docbook">
<title>What makes a phar a phar and not a tar or a zip?</title>
<section>
<section xml:id="phar.fileformat.ingredients" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<title>Ingredients of all Phar archives, independent of file format</title>
<para>
All Phar archives contain three to four sections:
@ -22,7 +22,7 @@
</orderedlist>
</para>
</section>
<section>
<section xml:id="phar.fileformat.stub" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<title>Phar file stub</title>
<para>
A Phar's stub is a simple PHP file. The smallest possible stub follows:
@ -67,7 +67,7 @@ __HALT_COMPILER();
<literal>.phar/alias.txt</literal> file as plain text.
</para>
</section>
<section>
<section xml:id="phar.fileformat.comparison" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<title>Head-to-head comparison of Phar, Tar and Zip</title>
<para>
What are the good and the bad things about the three supported file formats in
@ -173,7 +173,7 @@ __HALT_COMPILER();
</tip>
</para>
</section>
<section>
<section xml:id="phar.fileformat.tar" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<title>Tar-based phars</title>
<para>
Archives based on the tar file format follow the more modern USTAR
@ -190,7 +190,7 @@ __HALT_COMPILER();
archive, use <function>Phar::uncompressAllFiles</function>
</para>
</section>
<section>
<section xml:id="phar.fileformat.zip" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<title>Zip-based phars</title>
<para>
Archives based on the zip file format support several features built into
@ -203,7 +203,7 @@ __HALT_COMPILER();
as files with a trailing slash like <literal>my/directory/</literal>
</para>
</section>
<section>
<section xml:id="phar.fileformat.phar" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<title>Phar File Format</title>
<para>
The phar file format is literally laid out as stub/manifest/contents/signature, and
@ -277,7 +277,7 @@ __HALT_COMPILER();
</table>
</para>
</section>
<section>
<section xml:id="phar.fileformat.flags" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<title>Global Phar bitmapped flags</title>
<para>
Here are the bitmapped flags currently recognized by the Phar extension
@ -317,7 +317,7 @@ __HALT_COMPILER();
</table>
</para>
</section>
<section>
<section xml:id="phar.fileformat.manifestfile" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<title>Phar manifest file entry definition</title>
<para>
Each file in the manifest contains the following information:
@ -416,7 +416,7 @@ __HALT_COMPILER();
</table>
</para>
</section>
<section>
<section xml:id="phar.fileformat.signature" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<title>Phar Signature format</title>
<para>
Phars containing a signature always have the signature appended to the

View file

@ -1,9 +1,9 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.8 $ -->
<!-- $Revision: 1.9 $ -->
<chapter xml:id="phar.using" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<title>Using Phar Archives</title>
<section>
<section xml:id="phar.using.intro" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<title>Using Phar Archives: Introduction</title>
<para>
Phar archives are similar in concept to Java JAR archives, but are
@ -182,7 +182,7 @@ $a->stopBuffering();
</informalexample>
</para>
</section>
<section xml:id="phar.using.stream" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<section xml:id="phar.using.stream" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<title>Using Phar Archives: the phar stream wrapper</title>
<para>
The Phar stream wrapper fully supports <function>fopen</function> for