XML Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming Languages - MoreXML Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old March 10th, 2003, 10:31 AM
troutbum troutbum is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2003
Posts: 2 troutbum User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Post Xsl Date Value In Text Box

I would like to use current date function in vbscript to populate the date in a textbox. I am pretty new to xsl so if there is any good sites that would be helpful as well. I realize that I cannot use the "/" although I am not really sure why at this point. here is the code I have tried so far

<xsl:template match="/">
<div>
<form name="frmTime" id="frmTime" method="post" action="TimeLog.asp">
<Input Type="text">
<xsl:attribute name="txtSelectedDate">
<xsl:value-of select="<%=Replace(cstr(date), "/", "")%>"/>
</xsl:attribute>
</Input>
</form>
<br/>
<xsl:apply-templates select="SELECTDATE"/>
</div>
</xsl:template>

<xsl:template match="SELECTDATE">
<table class="timelog_catalog">
<xsl:element name="input">
<xsl:attribute name="type">text</xsl:attribute>
</xsl:element>
</table>
</xsl:template>

Reply With Quote
  #2  
Old March 17th, 2003, 08:37 AM
Number19 Number19 is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2003
Posts: 2 Number19 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
The problem you have is that you are trying to parse ASP inside XSL... that does not work, because the page has already been rendered to translate the XML. You cannot use server side language this way. Try using client-side script.

If you are generating a static ASP page from your XSLT and XML, (which I don't think you are doing), you can write out your ASP tags like this:

<xsl:text disable-output-escaping="yes"><%=ASPHERE%></xsl:text>

You can't use the <> in XSL...

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreXML Programming > Xsl Date Value In Text Box


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


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
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway