Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re: Problem with MIME::Parser and filenames

by tangent (Parson)
on Oct 10, 2017 at 21:40 UTC ( [id://1201123]=note: print w/replies, xml ) Need Help??


in reply to Problem with MIME::Parser and filenames

$parser->decode_headers(1);
I'm not sure if relevant, but from a quick look at the docs for MIME::Parser it says you should not use decode_headers() unless you really know what you are doing. Have you tried commenting out that line?

Replies are listed 'Best First'.
Re^2: Problem with MIME::Parser and filenames
by Laurielounge (Acolyte) on Oct 10, 2017 at 23:12 UTC
    Good idea. Didn't help though... exactly the same outcome.
      FWIW I sent myself a xlsx file with the same name as yours. It came in with the same Content-Type (application/vnd.openxmlformats-officedocument.spreadsheetml.sheet) and MIME::Parser saved the attached file correctly. So I don't think Content-Type is the problem. Could it be some type of filename length restriction - try adding something like this to your script:
      system('getconf NAME_MAX ' . $tmpdir);

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others goofing around in the Monastery: (5)
As of 2024-04-23 21:27 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found