xsl-list
[Top] [All Lists]

RE: [xsl] layout problem

2011-12-08 05:44:11

Work to do.,

 

The problem is as you look to http://test.tamarawobben.nl you see the head 
section and the bottom section but not the area where the text schould appear. 

 

You said I can use mode. Where can I find more info about xslt and modes. 


Roelof



----------------------------------------
Date: Thu, 8 Dec 2011 11:36:14 +0000
From: andrew(_dot_)j(_dot_)welch(_at_)gmail(_dot_)com
To: xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
Subject: Re: [xsl] layout problem

It's not clear what question you are asking...

Looking at your code you can make some improvments:

<xsl:template match="data">
<xsl:call-template name="section-content"/>
</xsl:template>

Don't do that ^^^^, just move the contents of the named template
'section-content' into the body of the template.

<body>
<xsl:call-template name="head"/>
<xsl:apply-templates />
<xsl:call-template name="bottom"/>
</body>

Instead of the call-template you should use apply-templates and modes.
If you really do have to use named templates, pass the context
explicitly as a parameter. The reason is it helps whoever maintains
the code down the line.

<xsl:template name="section-content">

change that to a match

<xsl:for-each select="section/entry">

change that to apply-templates


<xsl:template name="head">

<xsl:template name="bottom">

change those to matches with a mode


But if there a better way I will take that.

It's not clear what your problem is...


--
Andrew Welch
http://andrewjwelch.com

--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: 
<mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--
                                        
--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--

<Prev in Thread] Current Thread [Next in Thread>