Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[skalli-dev] Submitted bug 343937: Using a web context path other that "/" does not work

Hi all,

I just filed the bug https://bugs.eclipse.org/bugs/show_bug.cgi?id=343937.

I am using Skalli in an environment, where the web context path is not the root, but using a path like "/p" instead.

There is a lot of code, where it will be assumed that linking to servlets, JSPs, images, stylesheets etc. are located at "/".

I am just wondering what would be the best fix for it: a simple way would be to get the context path via

  request.getContextPath()

and prefix it in all code pieces where URIs will be generated.

Another option could be to add a helper method to ViewBundleUtil.java (http://git.eclipse.org/c/skalli/org.eclipse.skalli.git/tree/org.eclipse.skalli.view/src/main/java/org/eclipse/skalli/view/internal/ViewBundleUtil.java) to get a path for specific locations, e.g. VAADIN themes.

URLs to be called are implemented in org.eclipse.skalli.common.Consts. Probably we should provide a helper methods to make an URL based on the Consts too.


Any ideas about the best solution? I would be happy to contribute a patch which fixes the use of context paths.


Bye, Jochen

Back to the top