I got it... You want to have several files in the bz2 file, no? Does bz2 support that or do you have to tar it first? I think you just might have to tar it first.
-Dash -----Original Message----- From: Mikey [mailto:[EMAIL PROTECTED]] Sent: Monday, July 01, 2002 8:12 AM To: Adrian Ritchie; [EMAIL PROTECTED] Subject: RE: [PHP-WIN] Using Bzip2 to create an archive... SECOND REQUEST Sorry Adrian, this is from the manual and only shows how to compress a single string within an bz2 file - what I want to know how to do is compress a number of files within the file, creating an archive... (Much like the way the PHP manual is distributed) Mikey > -----Original Message----- > From: Adrian Ritchie [mailto:[EMAIL PROTECTED]] > Sent: 01 July 2002 13:11 > To: [EMAIL PROTECTED] > Subject: Re: [PHP-WIN] Using Bzip2 to create an archive... SECOND > REQUEST > > > <?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 > print bzread($bz, 10); > > // output until end of the file (or the next 1024 char) and close it. > print bzread($bz); > > bzclose($bz); > > ?> > > "Mikey" <[EMAIL PROTECTED]> wrote in message > [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > > OK, as I said - I have already read this - if you can find > where it shows > > how to create an *archive* within this compressed file, please let me > > know... > > > > Mikey > > > > > -----Original Message----- > > > From: Dash McElroy [mailto:[EMAIL PROTECTED]] > > > Sent: 25 June 2002 23:24 > > > To: '[EMAIL PROTECTED]'; '[EMAIL PROTECTED]' > > > Subject: RE: [PHP-WIN] Using Bzip2 to create an archive... SECOND > > > REQUEST > > > > > > > > > http://www.php.net/manual/en/ref.bzip2.php > > > > > > In particular, look at bzopen() and bzclose(), as well as bzread(). > > > > > > -Dash > > > > > > -----Original Message----- > > > From: Mikey [mailto:[EMAIL PROTECTED]] > > > Sent: Tuesday, June 25, 2002 3:23 PM > > > To: [EMAIL PROTECTED] > > > Subject: FW: [PHP-WIN] Using Bzip2 to create an archive... SECOND > REQUEST > > > > > > > > > > > > > > > > -----Original Message----- > > > > From: Mikey [mailto:[EMAIL PROTECTED]] > > > > Sent: 24 June 2002 18:42 > > > > To: [EMAIL PROTECTED] > > > > Subject: [PHP-WIN] Using Bzip2 to create an archive... > > > > > > > > > > > > Hi there! > > > > > > > > I was wondering if anyone here had used the bzip functions to create > an > > > > archive? The documentation shows only how to compress strings, > > > yet I want > > > > to create an archive similar to the HTML documentation > available from > > > > php.net > > > > > > > > TIA, > > > > > > > > mikey > > > > > > > > > > > > -- > > > > PHP Windows Mailing List (http://www.php.net/) > > > > To unsubscribe, visit: http://www.php.net/unsub.php > > > > > > > > > > > > > > > > > > > > > -- > > > PHP Windows Mailing List (http://www.php.net/) > > > To unsubscribe, visit: http://www.php.net/unsub.php > > > > > > > > > > > > -- > PHP Windows Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > > -- PHP Windows Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Windows Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php