php-doc-en/reference/bzip2/reference.xml
Nuno Lopes b069a314a4 add tagging
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@195136 c90b9560-bf6c-de11-be94-00142212c4b1
2005-09-04 19:39:32 +00:00

113 lines
2.4 KiB
XML

<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.7 $ -->
<!-- Purpose: compression -->
<!-- Membership: bundled, external -->
<reference id="ref.bzip2">
<title>Bzip2 Compression Functions</title>
<titleabbrev>Bzip2</titleabbrev>
<partintro>
<section id="bzip2.intro">
&reftitle.intro;
<para>
The bzip2 functions are used to transparently read and write bzip2 (.bz2)
compressed files.
</para>
</section>
<section id="bzip2.requirements">
&reftitle.required;
<para>
This module uses the functions of the <ulink url="&url.bzip2;">bzip2
</ulink> library by Julian Seward. This module requires bzip2/libbzip2
version &gt;= 1.0.x.
</para>
</section>
&reference.bzip2.configure;
<section id="bzip2.configuration">
&reftitle.runtime;
&no.config;
</section>
<section id="bzip2.resources">
&reftitle.resources;
<para>
This extension defines one resource type: a file pointer identifying
the bz2-file to work on.
</para>
</section>
<section id="bzip2.constants">
&reftitle.constants;
&no.constants;
</section>
<section id="bzip2.examples">
&reftitle.examples;
<para>
This example opens a temporary file and writes a test string to
it, then prints out the contents of the file.
</para>
<example>
<title>Small bzip2 Example</title>
<programlisting role="php">
<![CDATA[
<?php
$filename = "/tmp/testfile.bz2";
$str = "This is a test string.\n";
// open file for writing
$bz = bzopen($filename, "w");
// write string to file
bzwrite($bz, $str);
// close file
bzclose($bz);
// open file for reading
$bz = bzopen($filename, "r");
// read 10 characters
echo bzread($bz, 10);
// output until end of the file (or the next 1024 char) and close it.
echo bzread($bz);
bzclose($bz);
?>
]]>
</programlisting>
</example>
</section>
</partintro>
&reference.bzip2.functions;
</reference>
<!-- Keep this comment at the end of the file
Local variables:
mode: sgml
sgml-omittag:t
sgml-shorttag:t
sgml-minimize-attributes:nil
sgml-always-quote-attributes:t
sgml-indent-step:1
sgml-indent-data:t
indent-tabs-mode:nil
sgml-parent-document:nil
sgml-default-dtd-file:"../../../manual.ced"
sgml-exposed-tags:nil
sgml-local-catalogs:nil
sgml-local-ecat-files:nil
End:
vim600: syn=xml fen fdm=syntax fdl=2 si
vim: et tw=78 syn=sgml
vi: ts=1 sw=1
-->