6 Replies Latest reply on Mar 25, 2009 8:15 PM by norman

    Breakup or Modularize pages.xml

    dro_k

      Is it possible to have multiple pages.xml files and combine them together.


      I am working on a project with many pages and it would be really nice to have the admin/user/storefront page definitions in their own separate xml files.


      Thanks,


      Drew

        • 1. Re: Breakup or Modularize pages.xml
          cpopetz

          You can have a separate foo.page.xml for each foo.xhtml.


          (I'm not sure that's what you meant, but wanted to mention it in case you weren't aware of it.)


          • 2. Re: Breakup or Modularize pages.xml
            andygibson.contact.andygibson.net

            Here you go :


            Old Seam Forums Link


            Look for Norm Richards response, I believe this goes into the components.xml file.


            Cheers,


            Andy Gibson

            • 3. Re: Breakup or Modularize pages.xml
              dro_k

              This is exactly what I was looking for. Thanks

              • 4. Re: Breakup or Modularize pages.xml
                monkeyden

                I know this is an old post but I just sorted out the schema reference for Seam 2, so I figured I'd post it



                xmlns:navigation="http://jboss.com/products/seam/navigation"
                http://jboss.com/products/seam/navigation http://jboss.com/products/seam/navigation-2.0.xsd





                then you can use:


                <navigation:pages>
                    <navigation:resources>
                        <value>...</value>
                        <value>...</value>
                    </navigation:resources>
                </navigation:pages>



                • 5. Re: Breakup or Modularize pages.xml
                  dirk-mahler
                  Hi,

                  we tried to use this approach for our project which is highly modularized but we face a problem there:

                  We have two modules A and B, each of them provide a components.xml. Both descriptors contain the mentioned <navigation:pages> sections pointing to module specific pages.xml descriptors.
                  What we see is that this works only if one module is deployed. If both modules are deployed it seems that only one of the <navigation:pages> is evaluated.

                  Does anyone face the same problem and is there a solution for this?
                  • 6. Re: Breakup or Modularize pages.xml
                    norman

                    You would need to do this in Java code.  One option would be to capture one of the startup events to perform the configuration.  Another would be to subclass the Pages component to perform the custom configuration.