Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery
 
PerlMonks  

Re: $zip->addFile not working.

by arden (Curate)
on Jun 04, 2004 at 22:38 UTC ( [id://361243]=note: print w/replies, xml ) Need Help??


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?

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://361243]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others examining the Monastery: (3)
As of 2024-04-19 01:31 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found