Chris Lintz wrote:
Thanks for the response.  Yes I am using Wicket 1.3 Beta 2.  I First mapped
the WAR at root, and let everything fall through Apache with JkUnMounts
(i.e. JkUnMount /images default), but the issue is I could not solve the
problem of I did not want / served by wicket.

Basically it comes down to this.  I cannot seem to make a reference to
Wicket page on a path www.mydomain.com/myapp  from my static home page
www.mydomain.com because the relative path is "/" .  I need the Wicket
components to render under /myapp even from requests coming from / .

OK. I'm slightly confused at the moment, because you haven't quite specified well enough how you're trying to achieve this. Please could you clarify the following points:

 - What context path is your app running in? Is it the root?
 - Is Wicket running using a filter or a servlet?
 - Is Wicket mapped to "/myapp/*" in web.xml?
 - What is your mod_jk forwarding set-up, exactly?
   - You say you're forwarding from www.mydomain.com to
     www.mydomain.com/myapp, but obviously you're not quite,
     as otherwise you'd just get an infinite loop there. ;)
   - Specifically, where are your wildcards if there are any?

You seem to be concentrate too much on the specifics of what's wrong with your set-up, rather than what you're trying to achieve here.

As far as I can tell, you want to do the following:
 - Run a Wicket webapp on http://appserver.com:8080/
   (Note that's a root context path.)
 - Map Wicket to the root using servlet mapping/filter mapping of "/*".
 - Pass requests from an Apache which land on www.mydomain.com through
   to the Apache, unless they land on /myapp/*, in which case send them
   to Wicket.
 - You don't want your static resources served from within Tomcat.

Is that right?

Even if that's so, I still don't understand what specific issue you're having. Actually giving us some URLs might be illustrative here.

If you get a request for this:
 - www.myserver.com/myapp/path/to/mounted/page/

Assuming your context path is "/", that will get mapped to:
 - appserver.com:8080/path/to/mounted/page/

If you add a HeaderContributor with a ResourceReferences, or something similar, Wicket will give you URLs relative to that, so something like this in your generated HTML:
 - href="../../../../resources/com.company.HomePage/foo.css"

This will resolve to the following in your browser:
 - www.myserver.com/myapp/resources/com.company.HomePage/foo.css

...which is perfectly correct, as obviously Wicket needs to handle that.

So what exactly is going wrong for you here?

You say:

The problem is everything wicket related is written from the relative path (i.e. "/" ) not with the /myapp prefixed in front. Therefore, the component, Wicket Javascript references, etc are broke because of the relative path.

Broken how? Give us some specifics. This stuff should work just fine. You may be having issues with 302 redirects going to the wrong place, or cookie paths, but it doesn't sound like it. See the wiki page on mod_proxy for details.

Sorry, but better and less ambiguous question asking is required here...

Regards,

Al

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to