xsl-list
[Top] [All Lists]

Re: How to call a template that can generate a file name from an element

2004-01-14 09:11:45
Ian,

I haven't run your code and I'm not sure I understand the question exactly, but wonder if your problem isn't as simple as

  <xsl:template name="createBaseFrameFileName">
    <xsl:param name="element"/>

    <xsl:value-of select="$element[(_at_)name]"/>
 <!--    <xsl:value-of select="concat($outputDir,
$fileSep, $element[(_at_)name], '_index', '.html')"/> -->
  </xsl:template>

The template returns the value of the $element parameter, since $element[(_at_)name] returns $element itself if it has a @name attribute (which presumably it does), and its value is ... its value.

Maybe you want $element/@name?

Your template calling and usage of parameters all looks fine, to a cursory inspection.

Cheers,
Wendell


======================================================================
Wendell Piez                            
mailto:wapiez(_at_)mulberrytech(_dot_)com
Mulberry Technologies, Inc.                http://www.mulberrytech.com
17 West Jefferson Street                    Direct Phone: 301/315-9635
Suite 207                                          Phone: 301/315-9631
Rockville, MD  20850                                 Fax: 301/315-8285
----------------------------------------------------------------------
  Mulberry Technologies: A Consultancy Specializing in SGML and XML
======================================================================


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