Search code examples
phpdatemktime

Converting datestring from another language to timestamp in PHP


I have this date string in Dutch for example:

wo, 14 mei 2014 09:42:16

Is it possible to convert it to a timestamp? I was thinking about using the dutch language in mktime() but that returns FALSE ofcourse.


Solution

  • I would imagine http://php.net/manual/en/function.strptime.php or http://php.net/manual/en/function.date-parse-from-format.php (for php > 5.3) combined with setlocale would solve the problem.