Go Back   Velocity Reviews > Newsgroups > XML
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Reply

XML - resovling variable a tranform and run time .... Is this impossibleor not worth doing?

 
Thread Tools Search this Thread
Old 06-24-2003, 09:56 PM   #1
Default resovling variable a tranform and run time .... Is this impossibleor not worth doing?


The XSL code below generates the correct output for my html file.
I would like to run the transform once and have the the $yearM variable
be updated in the HTML.

I have played around with it and made a mess of it.
I can write a script to produce the date string for $yearM
but can not get it to integrate with with the HTML tag below.

<xsl:variable name="yearM">200306</xsl:variable>
<xsl:variable name="server" select="MM_NAME" />
<xsl:variable name="filen" select="TOOL_NAME" />

<a hef="http://{$server}/mmlogs/{$filen}{$yearM}"><xsl:value-of
select="TOOL_NAME"/></a>

above resolves to this:
<a href="http://usambara/mmlogs/ASHZ01ED200306">ASHZ01ED</a>

This script works in HTML.

<script type="text/vbscript">
if month(date) < 10 then
yearmonth= year(date)& "0" & month(date)
else
yearmonth= year(date) & month(date)
end if

</script>



Bill Sneddon
  Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump