Skip to content

Instantly share code, notes, and snippets.

@eddy8
Last active December 19, 2015 09:19
Show Gist options
  • Save eddy8/5932626 to your computer and use it in GitHub Desktop.
Save eddy8/5932626 to your computer and use it in GitHub Desktop.
获取一周前的时间
<?php
function a_week_ago(){
$today = getdate();
$start_time = mktime(0,0,0,$today['mon'],$today['mday']-7,$today['year']);
$end_time = time();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment