Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re^4: loading files

by Bass-Fighter (Beadle)
on Dec 22, 2008 at 13:55 UTC ( [id://732076]=note: print w/replies, xml ) Need Help??


in reply to Re^3: loading files
in thread loading files

he will not doing anything with the piece that filters the filename of the attachment. i get: Use of uninitialized value in string ne at emailprogramma3.txt line 71 (the line with if ($file ne ""){ in it) that is the place where I want to print the filename.
the other piece (mail::internet) works perfectly.

Replies are listed 'Best First'.
Re^5: loading files
by almut (Canon) on Dec 22, 2008 at 14:20 UTC

    Have you tried re-opening the file, or alternatively just seek($mail_fh,0,0) to re-position the file pointer to the beginning of the file?

    I didn't actually try it (because I don't have those modules installed), but the following statement from the documentation of Mail::Internet's new() method, i.e. "the new object will be initialized with headers and body" makes me suspect that the module might have already read the entire file (not just the headers), so the file pointer would need to be re-positioned for another read of the file (by MIME::Parser)...

Log In?
Username:
Password:

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

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

    No recent polls found