cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Giacomo Pati <Giacomo.P...@pwr.ch>
Subject Re: Browser Selector Bug
Date Mon, 30 Oct 2000 18:32:25 GMT
On Mon, Oct 30, 2000 at 03:41:18PM +0100, Carsten Ziegeler wrote:
> Sorry, the first email wasn't finished when my mailer decided to mail it....(AI is everywhere)
> 
> > Berin Loritsch [mailto:bloritsch@infoplanning.com]
> > 
> > The selector pattern needs to be tested and debugged.
> > Can you give me a sitemap that uses the selector pattern?
> > Something really simple, and I can try to do something
> > with it--since I am probably the one who broke it.
> > 
> OK, here is an example which worked weeks ago:
> 
>   <map:match pattern="hello.html">
>       <map:generate src="docs/samples/hello-page.xml"/>
> 	<map:select type="browser">
> 		<map:when test="explorer">
> 			<map:transform src="stylesheets/page/IE-html.xsl"/>
> 		</map:when>
> 		<map:when test="netscape">
> 			<map:transform src="stylesheets/page/NS-html.xsl"/>
> 		</map:when>
> 		<map:otherwise>
> 			<map:transform src="stylesheets/page/Unknown-html.xsl"/>
> 		</map:otherwise>
> 	</map:select>  
>       <map:transform src="stylesheets/page/simple-page2html.xsl"/>
>       <map:serialize type="html"/>
>    </map:match>

You don't even need to use different stylesheets for a test. Use the 
same <map:transform> for every <map:when> and <map:otherwise>.

Giacomo

-- 
PWR GmbH, Organisation & Entwicklung      Tel:   +41 (0)1  856 2202
Giacomo Pati, CTO/CEO                     Fax:   +41 (0)1  856 2201
Hintereichenstrasse 7                     Mobil: +41 (0)78 759 7703
CH-8166 Niederweningen                    Mailto:Giacomo.Pati@pwr.ch
                                          Web:   http://www.pwr.ch

Mime
View raw message