[Israel.pm] converting string to file name

Shlomi Fish shlomif at iglu.org.il
Mon Jun 7 03:00:35 PDT 2004

On Monday 07 June 2004 12:28, Itamar Elem wrote:
> hi
> ibe got pel string in var (say $buffer) and function which reuire  file
> name as one of its arguments(the function belong to external module. cant
> change) the file name content should be $buffer. here there away which i
> can convert $buffer sow i can send it to the function instead of the file
> name

Well, one option would be to create a temporary file on the disk with the 
contents of the buffer. Check:

$ perldoc -q "temporary file"

for a discussion on how to generate a temporary filename. 

Note that it would involve disk access, which would make it somewhat slow. But 
since the module expects a filename anyhow, it shouldn't be a major concern.


	Shlomi Fish

P.S.: Mr. Elem: please note that your E-mails are uncapitalized and full of 
typoes. This makes them extremely hard to read. Please make sure they are 
written in good style and quality of writing.


Shlomi Fish      shlomif at iglu.org.il
Homepage:        http://shlomif.il.eu.org/

Quidquid latine dictum sit, altum viditur.
        [Whatever is said in Latin sounds profound.]

More information about the Perl mailing list