You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lenya.apache.org by Felix Maeder <fe...@wyona.com> on 2003/04/17 16:23:23 UTC

href attribute in sitetree xml

Hi list,

The sitetree xml in the emerging default publication looks currently 
like this:

<site>
   <node href="demo/" label="Demo">
     <node href="unipublic.html" label="Unipublic"/>
     <node href="news.html" label="Wyona News and Comments"/>
     <node href="oscom.html" label="OSCOM"/>
   </node>
   <node href="download/" label="Download">
     <node href="source.html" label="Source Version"/>
     <node href="binary.html" label="Binary Version"/>
   </node>
</site>

I see a problem with the values of the href attribute. The href should 
just be "demo" or "unipublic" without "/" or ".html" suffix. It might 
even be replaced by an attribute called "id". Its function is to provide 
a node with an identifier, which can be used to build the url dynamically.
It is possible that the user adds a sub-page (resp. a child page) of the 
"unipublic" or the "news" page. So the menu.xsl that builds the 
navigation should insert and add the correct slashes and suffixes itself:
   <node href="demo" label="Demo">
     <node href="unipublic" label="Unipublic"/>
         <node href="introduction" label="Introduction"/>
     <node href="news" label="Wyona News and Comments"/>
     <node href="oscom" label="OSCOM"/>
   </node>
The menu.xsl will create the following URLs:
/demo.html
/demo/unipublic.html
/demo/unipublic/introduction.html
In this case, it is also possible to call different documents according 
to the language the user has selected:
/demo/unipublic.en.html
/demo/unipublic.de.html

-Felix




-- 
Felix Mäder          felix.maeder@wyona.com     +41 1 272 9163
                      Wyona AG, Hardstrasse 219, CH-8005 Zürich
Open Source CMS      http://www.wyona.org http://www.wyona.com


---------------------------------------------------------------------
To unsubscribe, e-mail: lenya-dev-unsubscribe@cocoon.apache.org
For additional commands, e-mail: lenya-dev-help@cocoon.apache.org