RSM*_*RSM 3 php date strtotime
如何在给定月份后获取月份名称.所以对于六月,我想要七月
我试过了:
$next_month = date('F',strtotime('June', "next month"));
Run Code Online (Sandbox Code Playgroud)
这显示一月,这显然是错误的,我正在寻找七月.
那我怎么能在前一个月得到?
我试过了
$prev_month = date('F',strtotime('June - 1 month'));
Run Code Online (Sandbox Code Playgroud)
Aar*_* W. 11
$next_month = date('F',strtotime('June + 1 month'));
Run Code Online (Sandbox Code Playgroud)
要么
$next_month = date('F',strtotime('June next month'));
Run Code Online (Sandbox Code Playgroud)
编辑
$next_month = date('F',strtotime('June last month'));
Run Code Online (Sandbox Code Playgroud)
归档时间: |
|
查看次数: |
4037 次 |
最近记录: |