[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: String manipulation question

Subject: Re: String manipulation question
From: Jeni Tennison <jeni@xxxxxxxxxxxxxxxx>
Date: Fri, 19 Jul 2002 16:46:07 +0100
date string manipulation
Hi Bodrul,

> I've never used any of these external libraries before. For future
> reference, do I just declare the library(eg EXSLT library) namespace
> and that's it!

Nope, you have to download the template somewhere local and import it
into your stylesheet. You also have to declare the namespace in order
to call the template:

<xsl:stylesheet version="1.0"
                xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
                xmlns:date="http://exslt.org/dates-and-times"
                exclude-result-prefixes="date">

<xsl:import href="date.format-date.template.xsl" />
...

  <xsl:call-template name="date:format-date">
    <xsl:with-param name="date-time" select="'2002-03-04'" />
    <xsl:with-param name="pattern" select="'d mmm yy'" />
  </xsl:call-template>

...
</xsl:stylesheet>

Actually, you probably need date.parse-date.template.xsl as well (or
instead -- I misinterpreted what you were doing) in order to get your
original date into the standard ISO format so that it can be
formatted.  See http://www.exslt.org/date/functions/parse-date/.

Cheers,

Jeni

---
Jeni Tennison
http://www.jenitennison.com/


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


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.