date / time help - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forumdisplay.php?fid=5) +--- Forum: General Help (https://forum.codeigniter.com/forumdisplay.php?fid=24) +--- Thread: date / time help (/showthread.php?tid=73141) |
date / time help - ninja258 - 03-22-2019 hello, i have something this but dont know how make it for month *check/reset every month, (i tried something but i don't know how test it, cannot wait for end of month) can someone help me remake it for months? (reset every month) Code: public function getWeekStartEnd() RE: date / time help - Wouter60 - 03-22-2019 Maybe this is helpful: To find the first day of the current month: PHP Code: $d = new DateTime('first day of this month'); To find the last day of the current month: PHP Code: $d = new DateTime('last day of this month'); |