in reply to $zip->addFile not working.

change the last line to $zip->addFile($fileWithPath) != AZ_OK || die "couldn't add $fileWithPath\n";

The single quotes are preventing the variable from being interpretted. Also, the author uses the AZ_OK constants for status. . .

- - arden.

update: Of course, I meant in your code, not in your post! Also added the AZ_OK info.
update2: As discovered in the CB, you must keep your $zip variable in scope when trying to execute methods on it! :)

Replies are listed 'Best First'.
Re^2: $zip->addFile not working.
by heigold1 (Acolyte) on Jun 04, 2004 at 22:47 UTC
    Hi Arden, I just took out the single quotes and it still isn't working. Any other ideas?