You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Juan Ignacio Jiménez de Luis <na...@ya.com> on 2003/12/02 20:47:53 UTC

Sitemap Syntax

	Greetings,

	I'm trying to simulate a hashmap with the XMLFileModule input module.. 
  I have an XML File with this structure

	<servers>
		<server url="www.unmardedatos.com">
			<site>unmarde</site>	
			<skin>basic</skin>
		</server>
		<server url="www.otherdomain.com">
			<site>unmarde</site>	
			<skin>shiny</skin>
		</server>
	</servers>


	I planned to reference that  in the sitemap as 
{xmlhashmap:/servers/server[@url='{request:serverName}']/site} to 
emulate a NamedVirtualServer behaviour.

	Unluckily, it seems that you can't nest variables in the sitemap.. 
Does anyone now any workarround to this limitation? Am I doing 
something wrong?

	Thanks in advance..

		Nacho Jiménez

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


Re: Sitemap Syntax

Posted by Christian Haul <ha...@informatik.tu-darmstadt.de>.
Juan Ignacio Jiménez de Luis wrote:
> 
>     Greetings,
> 
>     I'm trying to simulate a hashmap with the XMLFileModule input 
> module..  I have an XML File with this structure
> 
>     <servers>
>         <server url="www.unmardedatos.com">
>             <site>unmarde</site>   
>             <skin>basic</skin>
>         </server>
>         <server url="www.otherdomain.com">
>             <site>unmarde</site>   
>             <skin>shiny</skin>
>         </server>
>     </servers>
> 
> 
>     I planned to reference that  in the sitemap as 
> {xmlhashmap:/servers/server[@url='{request:serverName}']/site} to 
> emulate a NamedVirtualServer behaviour.
> 
>     Unluckily, it seems that you can't nest variables in the sitemap.. 
> Does anyone now any workarround to this limitation? Am I doing something 
> wrong?

No. This is not possible. But there is an InputModuleAction to your 
recue. Use that to access the xmlhashmap module and pass the 
request:serverName value to it.

	Chris.


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


[Cocoon 2.1] Read rtf file

Posted by Ling Kok Choon <ko...@brel.com>.
Greetings,

   I have a very basic problem with cocoon 2.1, where when i try to download / read a *.rtf file 
from browser, the browser popup a error download dialog. This happen once only every time after 
i reboot the tomcat. What could be problem ?

here is my sitemap.xmap

..
..
  <map:match pattern="**.rtf">      	      		        
       	<map:read src="{1}.rtf" mime-type="application/rtf"/>  
  </map:match>
..
..

fyi: I use tomcat 4.1.18 and jdk1.4.1

Thank you.

cheers,
Kok Choon.

--------------------------------------------------------
Ling Kok Choon                         kokchoon@brel.com
Brel Software Pte Ltd                  Tel: 65-6272-6800
Blk 1003 Bukit Merah Central           Fax: 65-6272-2811
#07-01                                 http://www.brel.com
Singapore 159836                       12/03/03 18:51:19
                    
           Pls call us for the following services
         Web Creation, Web, Email & Domain Hosting
           Java Devt B2B B2C ASP CMS E-Commerce

--------------------------------------------------------


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