xsl-list
[Top] [All Lists]

Re: [xsl] [xslt 2.0] Difference betwen functions and templates

2007-07-21 04:22:06
Hi Mike,
  Thanks for further educating me.

On 7/21/07, Michael Kay <mike(_at_)saxonica(_dot_)com> wrote:
> Now the questions is, is xsl:template name= ...
> able to do something, which xsl:function cannot do?

Depends what you count as "able to do something". For example, a named
template can declare default values for parameters. Does that count?

Yes, that's the difference which is significant for me. So I guess,
this is the only difference between named template & xsl:function? I
am not considering syntactic differences.

Yes, you can:

<xsl:template match="/">
 <result>
   <xsl:sequence select="xx:dummy-func()"/>
 </result>
</xsl:template>

Thanks for telling this to me. So for me, this difference does not
exist any more..

--
Regards,
Mukul Gandhi

--~------------------------------------------------------------------
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>
--~--