in reply to testing for a zip file
You can (in no particular order)
- call qx[ file $file ] and grep if the output says it's a ZIP file
- read the first few bytes and see if they match the string PK\003\004
- use Archive::Zip (this may or may not help)
|
---|
In Section
Seekers of Perl Wisdom