Advertisement
Guest User

Untitled

a guest
Jul 24th, 2016
57
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.65 KB | None | 0 0
  1.  if(!isset($_GET['date'])) {
  2.         $_GET['date'] = date('Y-m');
  3.       }
  4.       $start_date = new DateTime($_GET['date']);
  5.       $end_date = new DateTime($_GET['date']);
  6.       $lastMonth = new DateTime($_GET['date']);
  7.       $nextMonth = new DateTime($_GET['date']);
  8.       $start_date->modify("first day of this month");
  9.       $end_date->modify("last day of this month");
  10.       $lastMonth->modify("-1 months");
  11.       $nextMonth->modify("+1 months");
  12.       $lastMonth = $lastMonth->format('Y-m');
  13.       $nextMonth = $nextMonth->format('Y-m');
  14.       $month = $start_date->format('F Y');
  15.       $jobs = array();
  16.       $thisMonth = $start_date->format('Y-m');
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement