Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   Java (http://www.velocityreviews.com/forums/f30-java.html)
-   -   Aw: Re: Aw: Re: HTTP traffic over a custom proxy server? (http://www.velocityreviews.com/forums/t750447-aw-re-aw-re-http-traffic-over-a-custom-proxy-server.html)

Knorpi 06-24-2011 01:01 PM

Aw: Re: Aw: Re: HTTP traffic over a custom proxy server?
 
The htmlunit tip is great!

HtmlPage page = webClient.getPage(myURL);

This delivers the whole page, fine parsed with the DOM structure.

So I assume I can do the following things now:

- change all URLs in the document
- return the page content as a raw byte stream to the client

Well, page.asXml() delivers an XML stream, which is shown as XML code by the browser.

I also didn't find anything in the docs.

Could you point me into the right direction?

Thanks
Magnus

Lew 06-26-2011 06:05 PM

Re: Aw: Re: Aw: Re: HTTP traffic over a custom proxy server?
 
On 06/24/2011 09:01 AM, Knorpi wrote:
> The htmlunit tip is great!
>
> HtmlPage page = webClient.getPage(myURL);
>
> This delivers the whole page, fine parsed with the DOM structure.
>
> So I assume I can do the following things now:
>
> - change all URLs in the document
> - return the page content as a raw byte stream to the client
>
> Well, page.asXml() delivers an XML stream, which is shown as XML code by the browser.
>
> I also didn't find anything in the docs.
>
> Could you point me into the right direction?
>


The right direction is to stop using Google Groups in such a way that it
breaks the conversational thread.

--
Lew
Honi soit qui mal y pense.
http://upload.wikimedia.org/wikipedi.../c/cf/Friz.jpg


All times are GMT. The time now is 08:12 AM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.