Your skill will accomplish
what the force of many cannot
about retrieving and parsing html without writing on diskby limner (Novice)
|on Apr 09, 2018 at 21:26 UTC||Need Help??|
limner has asked for the wisdom of the Perl Monks concerning the following question:
Hi to all brothers monks
i've successfully wrote a perl script that retrieve an html page, parse it and prepare,
at the end a logfile from the html page.
In order to do this, at this moment, the program does the following:
1) unlink the file from disk, if exist on disk
2) retrieve in memory the correct html page
3) write on disk the html page on a standard filename (file.html)
4) read the file on disk (file.html) and parse it
5) write on disk the logfile
What i would like to do is avoid to write the "file.html" on disk and work only
in ram, so i would like to retrieve it, NOT write it on disk, and parse it in memory.
The following are the program lines that do this:
Everithing works as i would, but in this way every time i parse a page
i remove and write file.html in order to parse it.
How can i do everithin in memory without writing the file?