LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (http://www.linuxquestions.org/questions/linux-networking-3/)
-   -   URL download script (http://www.linuxquestions.org/questions/linux-networking-3/url-download-script-638224/)

gvp87 04-27-2008 01:31 PM

URL download script
 
Some time ago, I Googling something random, and I remember reading a short how-to on writing a short script(less than 5 lines) that downloads a URL(it didn't use wget or any other similar application).

I can't seem to find that how-to.

At the time it wasnt important at all, but now it would come in pretty handy.

does anyone have any idea what I'm talking about????? haha

giuseppe

rayfordj 04-27-2008 05:43 PM

afraid not with that little information. wget (or the similar) is what comes to my mind.

Do you have any recollection of how it went about doing it? Any detail on any of the lines of script?

gvp87 04-28-2008 12:02 AM

yea, i think it was something like :

/dev/something/something/"http://www.URL.com"


it was either /dev or /proc

fancylad 04-28-2008 09:59 PM

I doubt there is anything in these two directories that are capable of that. /dev contains special device files and /proc is an interface to the kerenel. What is wrong with using wget if it gets the job done? If you really need to write a script then try Perl or Python. I'm not sure if you can write a shell script that does this without using something like wget. I might be wrong. If I am I'd like to know how.

rayfordj 04-29-2008 06:53 AM

Quote:

Originally Posted by fancylad (Post 3136189)
I'm not sure if you can write a shell script that does this without using something like wget. I might be wrong. If I am I'd like to know how.

I'm with you on this one fancylad. wget, curl, lftp, i've even used nc to pull a file from the web before but i've never seen anything come from /proc or /dev...


There's generally a binary somewhere that does the leg-work for you on retrieving the page(s) and file(s) for your script to further handle and manipulate.


All times are GMT -5. The time now is 06:25 AM.