xsl-list
[Top] [All Lists]

RE: [xsl] Is there any way to identify the date format ?

2008-01-10 09:29:25
Am I missing something in the question? I can't see the difficulty. For
example,

contains(pubDate, ':')

Michael Kay
http://www.saxonica.com/ 

-----Original Message-----
From: jayashree venkatesh [mailto:jaya(_dot_)venk(_at_)yahoo(_dot_)com] 
Sent: 09 January 2008 07:13
To: xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
Subject: [xsl] Is there any way to identify the date format ?

Hello,
   
      I am a newbie to XSL . I have 2 XML feeds which have a 
pubdate tag having different date formats . One uses the 
standard RFC 822 format and the other non RFC 822 format.

1 st feed
-----------------
<pubDate>Mon, 07 Jan 2008 15:24:04 -0600</pubDate>    (RFC 822) 

2 nd feed
--------------------
<pubDate>March 7, 2007</pubDate>

I
want to convert both these date formats to ISO 8601 
format.The point is i want to do this in a single XSL file . 
I know there are substring() and concat() functions which can 
help me achieve this. Now my question is, how can I identify 
which format the date is ( 1st format or 2 nd ) in the first 
place ? If i can identify which format the date is in, I can 
covert them to ISO 8601 format.

Thanks in
 advance,
Jayashree Venkatesh



      
______________________________________________________________
______________________
Never miss a thing.  Make Yahoo your home page. 
http://www.yahoo.com/r/hs

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

<Prev in Thread] Current Thread [Next in Thread>