Re: wget and links to follow

[email protected]
Newsgroups gmane.comp.gnu.utils
Message-ID <[email protected]>
Andrea Rimicci <[email protected]> wrote:
> Hi all,
> I'd like retrieve a web document where some links are coded in
> javascript calls, so I'd like instruct wget when a something like
> JSfunc('my/link/to/follow/') is matched, he recognize
> 'my/link/to/follow/' as a link to follow.
> 
> Is there any way to accomplish this?
> Maybe using regexps, to setup which patterns will trigger the link,
> will be great.
> 
> TIA, Andrea

If I were doing this for myself, I think I would do a wget first to
get the files local and then use grep -R JSfunc to list all the
javascript commands retrieving additional files. I would pipe the
grep output to a smart script that would wget the additional files,
sticking them in the appropriate places. Also, the script could replace
in the local files the JSfunc call with <a href=...</a> so that no
javascript interpreter would be needed to access the files locally.

Dave Feustel
-- 
Using OpenBSD with or without X & KDE?
http://dfeustel.home.mindspring.com
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.