RE: getting Explorer to download New York Times every day
RE: getting Explorer to download New York Times every day
- Subject: RE: getting Explorer to download New York Times every day
- From: Joe Kelly <email@hidden>
- Date: Wed, 19 Dec 2001 19:33:04 -0800
I believe there might already be tools out there (written in C/C++) that do
what you want. But if you happened to be a code mutant, you might consider:
Use OpenURL or GetURL, and then GetSource, and store the source directly in
an xml tree. You'll need a fast database to keep track of cross references:
you'd walk the tree storing any anchor urls in a list and the database, and
replacing them with placeholder (also goes in the database) references,
write the xml to local disk. Then you do the same exact thing for each
anchor in your list. The end result is a farm of files with placeholder
anchors, and a database that maps placeholders to actual local file urls.
Then you'd just go through your files again substituting local file urls for
placeholders.
Considerations: if you have unlimited memory, you could eliminate writing
the xml to local disk as an intermediate step, and just keep the tree around
until you've spidered the site's extent. You have to deal with cyclic
references somehow. You have to invent some heuristic to keep yourself
within the site, and not wandering all over the place. I have not even
considered what to do with images, but they're fairly similar: store 'em all
in a cache folder, and do the placeholder substitution thing.
I'd have to say, however, writing such a thing in AppleScript is like
building a C compiler with Lisp. Yeah, sure, someone had lots of fun doing
it, and wow really impresses the relatives, but to be sure it will run
slower than dirt and will take alot of time to write.
joe
>
-----Original Message-----
>
From: email@hidden [mailto:email@hidden]
>
Sent: Wednesday, December 19, 2001 3:42 PM
>
To: email@hidden
>
Subject: getting Explorer to download New York Times every day
>
>
>
hey all...
>
>
i know nothing about applescript, but figured i'd throw this
>
out there and
>
see what responses i get.
>
>
i want to download the entire new york time every single
>
morning, for reading
>
and archving. i only have a dial-up, and it takes me forever
>
to read the
>
paper, so i'd rather just have it all tored on my machine,
>
for easy reading
>
throughout the day.
>
>
does anyone have any scripts/ideas for scrits that would do
>
this? it woud
>
have to tell explorer to go to the web site for the times
>
(www.nytimes.com)
>
and figure out the day's articles, and downad them all and
>
make them link
>
locally.
>
>
any ideas?!?!
>
>
thanks!
>
>
-matt
>
_______________________________________________
>
applescript-users mailing list | email@hidden
>
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.