HighDots Forums  

Web Page Downloader

alt.html alt.html


Discuss Web Page Downloader in the alt.html forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Chase Preuninger
 
Posts: n/a

Default Web Page Downloader - 05-08-2008 , 06:13 PM






I want to write a program that downloads web pages and replaces all
the relative URLs with absolute ones

EX. files/banner.jpg gets Replaced by http://www.mysite.com/files/banner.jpg

Where are the locations in which I would have to look to find a url
that needs to be replaced?

Reply With Quote
  #2  
Old   
dorayme
 
Posts: n/a

Default Re: Web Page Downloader - 05-08-2008 , 06:32 PM






In article
<50b24a1a-cdef-4a0a-aa70-575af5d3f53d (AT) j22g2000hsf (DOT) googlegroups.com>,
Chase Preuninger <chasepreuninger (AT) gmail (DOT) com> wrote:

Quote:
I want to write a program that downloads web pages and replaces all
the relative URLs with absolute ones

EX. files/banner.jpg gets Replaced by http://www.mysite.com/files/banner.jpg

Where are the locations in which I would have to look to find a url
that needs to be replaced?
Good question, I don't know if there is a general answer. I know that I
can do it often by S & R by targeting any href=" that does not have
after the " a http://

--
dorayme


Reply With Quote
  #3  
Old   
Ed Jay
 
Posts: n/a

Default Re: Web Page Downloader - 05-08-2008 , 08:33 PM



dorayme scribed:

Quote:
In article
50b24a1a-cdef-4a0a-aa70-575af5d3f53d...oglegroups.com>,
Chase Preuninger <chasepreuninger (AT) gmail (DOT) com> wrote:

I want to write a program that downloads web pages and replaces all
the relative URLs with absolute ones

EX. files/banner.jpg gets Replaced by http://www.mysite.com/files/banner.jpg

Where are the locations in which I would have to look to find a url
that needs to be replaced?

Good question, I don't know if there is a general answer. I know that I
can do it often by S & R by targeting any href=" that does not have
after the " a http://
Or do a universal search and replace on files/*.jpg.
--
Ed Jay (remove 'M' to respond by email)


Reply With Quote
  #4  
Old   
dorayme
 
Posts: n/a

Default Re: Web Page Downloader - 05-08-2008 , 09:40 PM



In article <0t6724t8h3gebjnd5dul9itg151k17j74o (AT) 4ax (DOT) com>,
Ed Jay <edMbj (AT) aes-intl (DOT) com> wrote:

Quote:
dorayme scribed:

In article
50b24a1a-cdef-4a0a-aa70-575af5d3f53d...oglegroups.com>,
Chase Preuninger <chasepreuninger (AT) gmail (DOT) com> wrote:

I want to write a program that downloads web pages and replaces all
the relative URLs with absolute ones

EX. files/banner.jpg gets Replaced by
http://www.mysite.com/files/banner.jpg

Where are the locations in which I would have to look to find a url
that needs to be replaced?

Good question, I don't know if there is a general answer. I know that I
can do it often by S & R by targeting any href=" that does not have
after the " a http://

Or do a universal search and replace on files/*.jpg.
No, the question was more general Ed.

--
dorayme


Reply With Quote
  #5  
Old   
Ed Jay
 
Posts: n/a

Default Re: Web Page Downloader - 05-08-2008 , 10:00 PM



dorayme scribed:

Quote:
In article <0t6724t8h3gebjnd5dul9itg151k17j74o (AT) 4ax (DOT) com>,
Ed Jay <edMbj (AT) aes-intl (DOT) com> wrote:

dorayme scribed:

In article
50b24a1a-cdef-4a0a-aa70-575af5d3f53d...oglegroups.com>,
Chase Preuninger <chasepreuninger (AT) gmail (DOT) com> wrote:

I want to write a program that downloads web pages and replaces all
the relative URLs with absolute ones

EX. files/banner.jpg gets Replaced by
http://www.mysite.com/files/banner.jpg

Where are the locations in which I would have to look to find a url
that needs to be replaced?

Good question, I don't know if there is a general answer. I know that I
can do it often by S & R by targeting any href=" that does not have
after the " a http://

Or do a universal search and replace on files/*.jpg.

No, the question was more general Ed.
Then do a general search and replace? :-)
--
Ed Jay (remove 'M' to respond by email)


Reply With Quote
  #6  
Old   
dorayme
 
Posts: n/a

Default Re: Web Page Downloader - 05-08-2008 , 10:09 PM



In article <50c724t05ckoak2v8fqqa7sbnetmlkaib6 (AT) 4ax (DOT) com>,
Ed Jay <edMbj (AT) aes-intl (DOT) com> wrote:

Quote:
dorayme scribed:

In article <0t6724t8h3gebjnd5dul9itg151k17j74o (AT) 4ax (DOT) com>,
Ed Jay <edMbj (AT) aes-intl (DOT) com> wrote:

dorayme scribed:

In article
50b24a1a-cdef-4a0a-aa70-575af5d3f53d...oglegroups.com>,
Chase Preuninger <chasepreuninger (AT) gmail (DOT) com> wrote:

I want to write a program that downloads web pages and replaces all
the relative URLs with absolute ones

EX. files/banner.jpg gets Replaced by
http://www.mysite.com/files/banner.jpg

Where are the locations in which I would have to look to find a url
that needs to be replaced?

Good question, I don't know if there is a general answer. I know that I
can do it often by S & R by targeting any href=" that does not have
after the " a http://

Or do a universal search and replace on files/*.jpg.

No, the question was more general Ed.

Then do a general search and replace? :-)
No, this is not right either because there is no such thing as a general
this. You have to be specific. Hence the problem. I am not meaning to be
awkward here Ed, it just comes naturally. <g>

--
dorayme


Reply With Quote
  #7  
Old   
Ed Jay
 
Posts: n/a

Default Re: Web Page Downloader - 05-09-2008 , 12:14 AM



dorayme scribed:

Quote:
In article <50c724t05ckoak2v8fqqa7sbnetmlkaib6 (AT) 4ax (DOT) com>,
Ed Jay <edMbj (AT) aes-intl (DOT) com> wrote:

dorayme scribed:

In article <0t6724t8h3gebjnd5dul9itg151k17j74o (AT) 4ax (DOT) com>,
Ed Jay <edMbj (AT) aes-intl (DOT) com> wrote:

dorayme scribed:

In article
50b24a1a-cdef-4a0a-aa70-575af5d3f53d...oglegroups.com>,
Chase Preuninger <chasepreuninger (AT) gmail (DOT) com> wrote:

I want to write a program that downloads web pages and replaces all
the relative URLs with absolute ones

EX. files/banner.jpg gets Replaced by
http://www.mysite.com/files/banner.jpg

Where are the locations in which I would have to look to find a url
that needs to be replaced?

Good question, I don't know if there is a general answer. I know that I
can do it often by S & R by targeting any href=" that does not have
after the " a http://

Or do a universal search and replace on files/*.jpg.

No, the question was more general Ed.

Then do a general search and replace? :-)

No, this is not right either because there is no such thing as a general
this. You have to be specific. Hence the problem. I am not meaning to be
awkward here Ed, it just comes naturally. <g
You awkwardly missed my smiley. ;-) <----- winky
--
Ed Jay (remove 'M' to respond by email)


Reply With Quote
  #8  
Old   
dorayme
 
Posts: n/a

Default Re: Web Page Downloader - 05-09-2008 , 02:32 AM



In article <krj724ddpvi8fk51id9sqbv1qt311606g0 (AT) 4ax (DOT) com>,
Ed Jay <edMbj (AT) aes-intl (DOT) com> wrote:

Quote:
dorayme scribed:

In article <50c724t05ckoak2v8fqqa7sbnetmlkaib6 (AT) 4ax (DOT) com>,
Ed Jay <edMbj (AT) aes-intl (DOT) com> wrote:

Or do a universal search and replace on files/*.jpg.

No, the question was more general Ed.

Then do a general search and replace? :-)

No, this is not right either because there is no such thing as a general
this. You have to be specific. Hence the problem. I am not meaning to be
awkward here Ed, it just comes naturally. <g

You awkwardly missed my smiley. ;-) <----- winky
But you smoothly and elegantly *noted* my <g> <------- grin ?

--
dorayme


Reply With Quote
  #9  
Old   
viza
 
Posts: n/a

Default Re: Web Page Downloader - 05-09-2008 , 03:09 AM



Hi

On May 8, 11:13 pm, Chase Preuninger <chasepreunin... (AT) gmail (DOT) com>
wrote:
Quote:
I want to write a program that downloads web pages and replaces all
the relative URLs with absolute ones

EX. files/banner.jpg gets Replaced byhttp://www.mysite.com/files/banner.jpg

Where are the locations in which I would have to look to find a url
that needs to be replaced?
You are reinventing the wheel:

http://www.gnu.org/software/wget/

Use the -k option without the -p option.

HTH

viza


Reply With Quote
  #10  
Old   
Chase Preuninger
 
Posts: n/a

Default Re: Web Page Downloader - 05-09-2008 , 08:22 AM



I was talking about something that downloads a web page so that it
will still work fine in a browser so that means replacing any
references to an external resource.

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.