[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: what am I missing?

Subject: RE: what am I missing?
From: Carlton Noles <nolesce@xxxxxxxxx>
Date: Sun, 13 May 2001 13:45:28 -0700 (PDT)
carlton font
Thanx everyone for the help. The crux of the last
problem was the namespace issue. BTW Chris when I said
I patterned it after your example I meant as far as
the choose and filtering was concerned, the other
templates i lifted from another project I wrote. They
worked there but that was a different namespace and
thus the problem. on to the next issue...

on a new project I am using the filtering as a TOC on
an xml with this structure....

volume/
  Title/
  Credit/
  Credit/
  Credit/
  Book
    bTitle/
    intro/
    verse
      vNumber/
      paragraf/
      paragraf/
    /verse
  /book
  book
  .
  .
  .
  /book
/volume  

as you have probably guessed I am having problems with
the <Credit> and <Paragraf> elements. I used an
xsl:for-each (tho i was told not to) ;{)} and that at
least saw all the paragrafs but didn't render them,
just gave me a <br/> for each one. here is the xsl
what should I do to display the Paragraf's and the
Credit's.

<?xml version='1.0' ?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:param name="book"  />
	<xsl:template match="*|@*">			
	 	<xsl:copy>
	 		<xsl:apply-templates select="@* | * | comment() |
processing-instruction() | text()"/>
	 	</xsl:copy>
	</xsl:template>
	<xsl:template match="Volume">
  		<html>
  		<title><xsl:value-of select="Title" /></title>
  		<head>
			<script language="Javascript" src="filtertao.js" />
  		</head>      	             
  		<body bgcolor="white" style="color:navy;font=12pt
Trebuchet">
		<h1 style="font:36pt Monotype
Corsiva;color:maroon"><xsl:value-of
select="Title"/></h1>
      		<HR color="Maroon"/><BR/>
                
                <xsl:apply-templates select="Credit"/>
		
      		<xsl:choose>
			<xsl:when test="$book">
				<xsl:apply-templates select="Book[bTitle=$book]"
mode="single" />
			</xsl:when>
			<xsl:otherwise>
				<xsl:apply-templates select="Book" />
			</xsl:otherwise>   
     		</xsl:choose> 
  		</body>
  		</html>
	</xsl:template>
	<xsl:template match="Credit">	
		<xsl:value-of select="Credit"/>
	</xsl:template>
	<xsl:template match="Book">
		
      
       		<strong style="color:Navy;font:16pt Arial"><A
style="text-decoration:none;color:navy">
			<xsl:attribute name="onclick">filter('<xsl:value-of
select="bTitle"/>')</xsl:attribute>
		<xsl:value-of select="bTitle"/><br/> </A></strong>
       

      		
	</xsl:template>
	<xsl:template match="Book" mode="single">
		<strong style="color:Navy;font:16pt
Arial"><xsl:value-of select="bTitle"/></strong><BR/>
       		Thus Spake The Master Programmer:<br/>
		<span style="color:maroon"><xsl:value-of
select="intro"/></span><BR/>
       		<xsl:apply-templates select="verse"/>
		<br/>
		<a href="Javascript:filter('')">BACK</a>
	</xsl:template>
	<xsl:template match="verse">
		
		<B
style="color:gold;background-color:maroon;font:25pt
Monotype Corsiva"><xsl:value-of
select="vNumber"/>.</B><br/>
			
			<xsl:apply-templates select="Paragraf"/><br/>
		


	</xsl:template>
	<xsl:template match="Paragraf">
		<xsl:value-of select="Paragraf"/>
	</xsl:template>
</xsl:stylesheet>


here  i go again making a fool of myself...
Carlton Noles
 

__________________________________________________
Do You Yahoo!?
Yahoo! Auctions - buy the things you want at great prices
http://auctions.yahoo.com/

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.