Problem with gzuncompress

Do you have a question? Post it now! No Registration Necessary.  Now with pictures!

Threaded View

I am trying to create a simple form that, when submitted, will
uncompress a string entered in a textarea using gzuncompress.

The entire HTML is below:


if (isset($_GET['action'])) {
    if ($_GET['action'] == "decompress") {
        $newtext = gzuncompress(stripslashes($_POST['textarea']));

<form name="form1" method="post"
  <textarea name="textarea" rows="8"><?php if (isset($newtext)) echo
$newtext; ?></textarea>
  <input type="submit" name="Submit" value="Submit">

To simplify things for now I have just been trying to use a very basic

xœËHÍÉÉ, - which is the result of gzcompress("hello")

Unfortuntely it stumbles on the line that reads:

$newtext = gzuncompress(stripslashes($_POST['textarea']));

Giving the following error:

Warning: gzuncompress(): data error in
/home/martyn69/public_html/test/gzuncompress.php on line 5

Why can it not decompress it?



Re: Problem with gzuncompress

well, anyone?

Re: Problem with gzuncompress

On 28 Jul 2005 12:03:24 -0700, wrote:
Quoted text here. Click to load it

Just _what_ are you nattering on about?
Oh, I see the problem:

Site Timeline