Re: Separate deployment, FilesystemResourceManagerFactory, CSS problem

Posted by stessy on
URL: https://discuss.orbeon.com/Separate-deployment-FilesystemResourceManagerFactory-CSS-problem-tp1560229p1565704.html

Erik,

I think that I still have to read deeper the url rewriting mechanism implemented in Orbeon.
Because now here is what I have and that works.

orbeon web.xml

<context-param>
        <param-name>oxf.resources.priority.1</param-name>
        <param-value>org.orbeon.oxf.resources.FilesystemResourceManagerFactory</param-value>
    </context-param>
    <context-param>
        <param-name>oxf.resources.priority.1.oxf.resources.filesystem.sandbox-directory</param-name>
        <param-value>D:\\temp\\orbeon-forms\\resources</param-value>
    </context-param>

Now inside "resources" folder I have to create a new folder "epss" and than reproduce the following structure: apps -> epss-forms-> css -> epss-forms.css

and in the view.xhtml, add the following path in link

<xhtml:link rel="stylesheet" type="text/css" href="/orbeon/apps/epss-forms/css/epss-forms.css"/>

Same think for the images folder

apps -> epss-forms -> images -> *.jpg

and then

<xhtml:div class="fourcols middle">
     <xforms:output mediatype="image/*" value="'/orbeon/apps/epss-forms/images/CP-IP-A1.gif'"/>
</xhtml:div>

Now when I launch the following url: http://localhost:7101/epss/orbeon/epss-forms/
It works and the stylesheet is applied
Inside the html, you can see the following path inside link tag
<link rel="stylesheet" type="text/css" href="/epss/orbeon/apps/epss-forms/css/epss-forms.css"> 

To be honest, I don't know why it works, but it does the job :-)

If you have any advise, it's welcome.


Regards,
Stessy