更新时间:2021-08-24 22:19:21
the_date()
需要在循环中使用。在循环外部,它将返回null。改为使用 current_time()。
the_date()
needs to be used within the Loop. Outside the Loop, it will return null. Use current_time() instead.
$todays_date = current_time('mysql'); // returns YYYY-MM-DD HH:MM:SS