You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Lorin Kobashigawa-Bates <lo...@robot6.com> on 2000/07/04 02:16:38 UTC

Including remote content

Is it possible to include content from a remote server?  I am looking for
something like RequestDispatcher.include(request, response) for a page that
is on an affiliated site.

-Lkb




Re: Including remote content

Posted by ALEXANDROS KOTSIRAS <AL...@prodigy.net>.
I don't think that it is possible to include content from a remote server.
You can instead write a short utility that reads some content from a web
page from a remote server by use
of the URLConnection class. You can have the utility read the source of the
HTML page at Tomcat startup (in the init() method of a servlet)  and save it
in a String in the ServletContext. Then you can output that source from
every JSP page without reading from the remote server for every request.

----- Original Message -----
From: Lorin Kobashigawa-Bates <lo...@robot6.com>
To: <to...@jakarta.apache.org>
Sent: Monday, July 03, 2000 8:16 PM
Subject: Including remote content


> Is it possible to include content from a remote server?  I am looking for
> something like RequestDispatcher.include(request, response) for a page
that
> is on an affiliated site.
>
> -Lkb
>
>
>
>
> --------------------------------------------------------------------------
> To unsubscribe, email: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commmands, email: tomcat-user-help@jakarta.apache.org
>


Re: Including remote content

Posted by Alex Chaffee <gu...@edamame.stinky.com>.
Read the FAQ!

http://www.jguru.com/jguru/faq/view.jsp?EID=23327

:-)

 - Alex

On Mon, Jul 03, 2000 at 05:16:38PM -0700, Lorin Kobashigawa-Bates wrote:
> Is it possible to include content from a remote server?  I am looking for
> something like RequestDispatcher.include(request, response) for a page that
> is on an affiliated site.
> 
> -Lkb
> 
> 
> 
> 
> --------------------------------------------------------------------------
> To unsubscribe, email: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commmands, email: tomcat-user-help@jakarta.apache.org

-- 
Alex Chaffee                       mailto:alex@jguru.com
jGuru - Java News and FAQs         http://www.jguru.com/alex/
Creator of Gamelan                 http://www.gamelan.com/
Founder of Purple Technology       http://www.purpletech.com/
Curator of Stinky Art Collective   http://www.stinky.com/