0

Is it possible to access non shared resources (web application resources XHTML / CSS ) from shared resource which is packaged as JAR file and placed inside WEB-INF/lib folder.

Eg. App
--views
---layout
----template.xhtml

--WEB-INF
----lib
------jar1
--- ----META-INF
----------resource
------------views --------------index.xhtml

In the above structure can index.xhtml reuse template.xhtml? I wanted to have application specific template rather than using it from shared template.

3
  • Did you tried to access? Did you tried anything? And if you tried and have some errors than post those errors. Commented Mar 15, 2013 at 11:22
  • Corrected my original question as mentioned wrong path for couple of files. I have figured out the problem and solved it by providing full relative path starting from app context. <br> Eg. provided template=views/layout/template.xhtml instead of template=layout/template.xhtml in index html <br> @partlov thanks for your quick response Commented Mar 15, 2013 at 12:22
  • You should provide an answer to your own question. Commented Mar 15, 2013 at 12:24

1 Answer 1

0

@Partlov,

As I mentioned earlier, Have solved by providing relative path starting from app context rather then from current folder.

In facelet tag declaration have used template=/views/layout/template.xhtml instead of template=layout/template.xhtml in WEB-INF/lib/jar1/Index.xhtml

@BalusC, Thanks for your note. I do agree your comment.

Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.