Thanx Michael and all! ;-)
Works fine! Only one tip:
<cfset findDate=ReFind("[0-9]{4}-[0-9]{2}-[0-9]{2}
[0-9]{2}:[0-9]{2}:[0-9]{2}\.[0-9]{1,3}",local.datePI,1,'true')>
<cfset position = findDate.pos[1]>
<cfset length = findDate.len[1]>
<cfset local.datePI=Mid(local.datePI,position,length)>
I include {1,3} to get milliseconds(from 0 to 999).
Thanx again
2007/5/3, Michael Dinowitz <[EMAIL PROTECTED]>:
>
> Do you want it 'smart' or just plain?
> [0-9]{4}-[0-9]{2}-[0-9]{2} [0-9]{2}:[0-9]{2}:[0-9]{2}\.[0-9]
> This simply says 4 numbers followed by a dash followed by 2 numbers
> followed
> by a dash followed by 2 numbers then a space then 2 numbers,a colon, 2
> numbers, a colon, 2 numbers, a period and then a single number.
> A smarter one would be written to evaluate the fact that each 'part' is
> correct so you will not get a month of 14 or a day of 45.
>
> > Hi all
> >
> > I'm parsing an HTML page with CFHTTP and need to find and get a date
> > inside
> > that. Do you know any regex to find a date in a string like this Date:
> > 2007-05-03 08:11:29.0 ????
> >
> >
> >
>
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Macromedia ColdFusion MX7
Upgrade to MX7 & experience time-saving features, more productivity.
http://www.adobe.com/products/coldfusion?sdid=RVJW
Archive:
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:276954
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe:
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4