Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有这样的字符串:Thu, 27 May 2010 07:00:00 GMT
Thu, 27 May 2010 07:00:00 GMT
我想将它们转换为 UNIX 时间戳
有什么办法吗?
echo strtotime('Thu, 27 May 2010 07:00:00 GMT');
http://php.net/manual/en/function.strtotime.php
是的,有办法!事实上,有不止一种方法可以做到!;)
您可以使用 strtotime();
$time_en = "Thu, 27 May 2010 07:00:00 GMT" $time = strtotime($time_en);
http://fr2.php.net/manual/fr/function.strtotime.php