xsl-list
[Top] [All Lists]

RE: [xsl] Convert to RFC822 via XSLT? Doable?

2007-03-28 15:01:50
It is pretty easy with exslt. If your XSLT processor doesn't support it,
you can use the XSLT Template.

Research here:
http://www.exslt.org/date/functions/format-date/index.html


-----Original Message-----
From: Austin, Darrel 
[mailto:Darrel(_dot_)Austin(_at_)courts(_dot_)state(_dot_)mn(_dot_)us] 
Sent: Wednesday, March 28, 2007 3:05 PM
To: xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
Subject: [xsl] Convert to RFC822 via XSLT? Doable? 

The XML I am trying to convert to RSS XML stores the pubDate as such:

  2007/03/28

RSS needs it to be in RFC822 format:

  Wed, 28 Mar 2007 12:00:00 CST

After some googling, I'm not even sure this should be attempted in XSL.
It look like using the tostring("R") function asp.net (or date('r') in
PHP) looks like the better option and just get the dats in the RFC822
format PRIOR to making the XML.

However, maybe there is a fairly painless way to go from one date format
to the other in XSLT. So, thought I'd ask in here. ;o)

-Darrel

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


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