in reply to Regexp for date

I suspect an XY Problem. If you really want to go down the regex path, I'd suggest you have a look at the Regular Expression Library.

HTH,

planetscape

Replies are listed 'Best First'.
Re^2: Regexp for date
by Anonymous Monk on Mar 30, 2008 at 13:49 UTC

    This is a follow up post:

    I am thinking to have an much universal solution that match anything like a date, so that I can cut a chunk of text by date where a date appear (That is why I don't need them to be valid)

    The problem I encounter is: There is too much date format that appear in the document I need to process:
    2008-03-04
    2008-3-4
    2008-03-4
    2008-3-04
    or
    03-04-2008
    3-4-2008
    and so on hypen, common, slash are possible as seperator
    Also US and british style may appear