tomcat-taglibs-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject Re: relative paths and c:import
Date Tue, 22 Nov 2005 20:07:19 GMT
On Tue, Nov 22, 2005 at 06:38:34PM +0100, Martin Kindler wrote:
> Isn't there another solution? I do control both servers but forcing to use
> absolute URLs via a CMS would be a problem.
> I can imagine witing sort of a wrapper to adapt the result of c:import, but
> this must be a common problem. So I hope someone has already done the job?

You could try to write a bunch of regex's to do things like
 s/<img src="...">/<img src="http:...">/
(good luck.  let me know which insane asylum you check into.)

Depending on the structure of your site, you could also try putting the
CMS servers content in an iframe.  Of course, that completely sidesteps
the whole issue since your jsp won't actually be doing the import anymore,
so it doesn't work if you fiddling with the data in any way.

Why is using absolute URLs a problem?  It's really the _only_ way to
refer to content that's on a different server.

If you are actually processing the data from the CMS server in your jsp page
the best way to fix it would probably be to have the jsp page entirely parse 
out the imported content and regenerate it.  Of course, that's going to be
a bit more work, and you'll probably want to communicate using xml instead
of an arbitrary web page from the CMS web server.


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message