2 Replies Latest reply on Jan 27, 2007 2:42 PM by chris1

    Themes: multiple CSS per theme?

    faerine

      I am converting a single-theme SEAM application to one that uses multiple themes (allowing the user to switch them), and I cannot find information regarding themes with multiple CSS.

      Is it possible to include multiple CSS in a single theme.properties file (together with a single template). Then, if it is possible, how can different CSS from the same theme be selected on a Facelets page ( assumes a single CSS only, and does not give choice as to which CSS to be applied shen, or to what exactly).

      An alternative solution might be to create separate themes, each with a single tempate and a single CSS, for all needs addressed by the current multiple CSS. Currently, there is a screen CSS, print CSS, etc. In this case, there would be a theme for template 1 with CSS 1, another theme for tempate 1 with CSS 2, etc., which seems redundant to me.

        • 1. Re: Themes: multiple CSS per theme?
          chris1

          Hi Faerine,

          pretty easy because you can just as many key/value pairs as you need in your theme-properties file:

          My theme file (default.properties):
          css /dvdb-assets/main/css/main.css
          cssforms /dvdb-assets/global/css/wforms.css template3cols /WEB-INF/templates/page/template3cols.xhtml
          template2cols /WEB-INF/templates/page/template2cols.xhtml

          My xhtml-template:



          Chris

          • 2. Re: Themes: multiple CSS per theme?
            chris1

            Here is the template:

            <link href="#{theme.cssforms}" rel="stylesheet" type="text/css" />
            <link href="#{theme.css}" rel="stylesheet" type="text/css" />
            


            -Chris