RE: XML include

2002-09-18 Thread Ryan Agler

There are lots of different ways to achieve that effect with
map:aggregate and im sure some tag libraries I have yet to explore :)
Or you can do this in an XML file:

?xml version=1.0?
!DOCTYPE include [!ENTITY theInc SYSTEM ../docs/blahblah.xml]
doc
theInc;
/doc

-Original Message-
From: Andrés Tobelem [mailto:[EMAIL PROTECTED]] 
Sent: Wednesday, September 18, 2002 8:39 AM
To: [EMAIL PROTECTED]
Subject: XML include

Hi
 
How can i include one xml in another.
 
 
Tobe

-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail:   [EMAIL PROTECTED]




RE: XML include

2002-09-18 Thread Ryan Agler

Something like that would work -- or, you could also transform it
further if you needed to embed one of the xml files inside the other,
rather than them both being children of page

xsl:template match=/page
   xsl:apply-templates select=informacion/
/xsl:template
xsl:template match=informacionInsertionPoint
   xsl:copy-of select=/page/principal/
/xsl:template
xsl:template match=@*|node() priority=-1
  xsl:copy
xsl:apply-templates select=@*|node()/
  /xsl:copy
/xsl:template



-Original Message-
From: Andrés Tobelem [mailto:[EMAIL PROTECTED]] 
Sent: Wednesday, September 18, 2002 8:57 AM
To: [EMAIL PROTECTED]
Subject: Re: XML include

So you think that is a good idea to do something like this?

 map:match pattern=home.xml
  map:aggregate element=page
   map:part src=cocoon:/contenido/general/informacion.xml/
   map:part src=cocoon:/contenido/principal/principal.xml/
  /map:aggregate
map:serialize type=xml/
  /map:match




Thank you very much
- Original Message -
From: Ryan Agler [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, September 18, 2002 11:46 AM
Subject: RE: XML include


There are lots of different ways to achieve that effect with
map:aggregate and im sure some tag libraries I have yet to explore :)
Or you can do this in an XML file:

?xml version=1.0?
!DOCTYPE include [!ENTITY theInc SYSTEM ../docs/blahblah.xml]
doc
theInc;
/doc

-Original Message-
From: Andrés Tobelem [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, September 18, 2002 8:39 AM
To: [EMAIL PROTECTED]
Subject: XML include

Hi

How can i include one xml in another.


Tobe

-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail:   [EMAIL PROTECTED]


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail:   [EMAIL PROTECTED]

-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail:   [EMAIL PROTECTED]




Re: XML include for masthead and navigation

2001-12-05 Thread Adrian Geissel
Title: Message



Richard,

Have a look at map:aggregate/ and 
map:part/ in the sitemap. This allows you to merge mulitple XML sources, 
and then transform using a single xml-html stylesheet.

Hope this helps,
Adrian

  - Original Message - 
  From: 
  therandthem 
  To: [EMAIL PROTECTED] 
  Sent: Tuesday, December 04, 2001 6:13 
  PM
  Subject: XML include for masthead and 
  navigation
  
  I know that this 
  list is for Cocoon specific questions but with so many options available to me 
  in Cocoon, I thought I might ask it here.
  
  I am using Cocoon 
  2 and would like to have standard headers and footers on every page. I 
  have my site navigation in the Header. I would like the navigation to 
  get its information from a totally seperate XML file that only has data (no 
  presentation, XSL or logic, XSP). Something like 
  this:
  
  menu
   item 
  name="Home" uri="/welcome"
   
  item name="Services" uri="/services"/
   
  item name="Products" uri="/services"/
   
  /item
   item 
  name="About Us" uri="/aboutus"
  /menu
  
  I don't want my 
  individual pages to have any concept of this "menu.xml" file. I'd like 
  to reference"menu.xml"from somewhere like XSL, read in the values 
  and prepend the generated pages with the Header and this navigation 
  content. The end result being, I can add and remove values from one file 
  and have it can the navigation on all pages, instantly. What is the most 
  simple way to do this in Cocoon 2?
  
  Thanks for any 
  help,
  
  Richard