Re: [Hypercontent-users] xsl question
Brought to you by:
alexvigdor
From: Alex V. <av...@co...> - 2005-09-28 14:59:13
|
Hi Carl, Offhand, I don't see any obvious problems. I would print out <xsl:value-of select="$sourceItem/@location"/:> just before or after that choose, for a debugging reality check - make sure the value you're testing matches the tests. -Alex On Sep 28, 2005, at 10:41 AM, Carl Barrow wrote: > Hi > > I want to use a different graphic in my layout depending on where the > page is in the site, I've tried the following but it always goes > though to the <xsl:otherwise> statement. Can anyone tell me why? > > Many thanks > Carl > > > <xsl:choose> > <xsl:when > test="starts-with($sourceItem/@location,'/departments/ > academic_departments/applied_science_tech/')"> > <a href = "http://www.hull.ac.uk"> <img src = > "http://www.acsweb.hull.ac.uk/media/pt_icon_default_alt_scitech.jpg" > width = "28" > height = "28" > border = "0" > class = "body" > alt = "University Home Page"/></a> > </xsl:when> > <xsl:when > test="starts-with($sourceItem/@location,'/departments/ > academic_departments/arts_social_science/')" > > <a href = "http://www.hull.ac.uk"> > <img src = > "http://www.acsweb.hull.ac.uk/media/pt_icon_default_alt_artsoc.jpg" > width = "28" > height = "28" > border = "0" > class = "body" > alt = "University Home Page"/></a> > </xsl:when> > <xsl:otherwise> > <a href = "http://www.hull.ac.uk"> <img src = > "http://www.acsweb.hull.ac.uk/media/pt_icon_default_alt.gif" > width = "28" > height = "28" > border = "0" > class = "body" > alt = "University Home Page"/></a> > </xsl:otherwise> > </xsl:choose> > > -- > ************************************ > > Carl Barrow > Systems Integrator > e-Services > The University of Hull > Cottingham Road > Hull > HU6 7RX > Ext. 6838 > ************************************ > > > > ------------------------------------------------------- > This SF.Net email is sponsored by: > Power Architecture Resource Center: Free content, downloads, > discussions, > and more. http://solutions.newsforge.com/ibmarch.tmpl > _______________________________________________ > Hypercontent-users mailing list > Hyp...@li... > https://lists.sourceforge.net/lists/listinfo/hypercontent-users |