Parse date from filename

    Date: 01/03/08 (PHP Community)    Keywords: no keywords

    I need help with creating a RegEx to parse a date from the filename.

    $filename = 'Foobar2007-09-12.pdf'

    preg_match('?(19|20)[0-9]{2}[- /.](0[1-9]|1[012])[- /.](0[1-9]|[12][0-9]|3[01])/i', $filename, $matches);

    Source: http://community.livejournal.com/php/608488.html

« Problem with GET method... || DATETIME »


antivirus | apache | asp | blogging | browser | bugtracking | cms | crm | css | database | ebay | ecommerce | google | hosting | html | java | jsp | linux | microsoft | mysql | offshore | offshoring | oscommerce | php | postgresql | programming | rss | security | seo | shopping | software | spam | spyware | sql | technology | templates | tracker | virus | web | xml | yahoo | home