public function time()
{
$today = date("Y-m-d");
$day = $this->getthemonth($today);
if ($day[0] == $day[1]) {
return True;
} else {
return False;
}
}
function getthemonth($date)
{
f i r s t d a y = d a t e ( ′ Y − m − 0 1 ′ , s t r t o t i m e ( firstday = date('Y-m-01', strtotime( firstday=date(′Y−m−01′,strtotime(date));
n o w d a y = d a t e ( ′ Y − m − d ′ , s t r t o t i m e ( nowday = date('Y-m-d', strtotime( nowday=date(′Y−m−d′,strtotime(date));
l a s t d a y = d a t e ( ′ Y − m − d ′ , s t r t o t i m e ( " lastday = date('Y-m-d', strtotime(" lastday=date(′Y−m−d′,strtotime("firstday +1 month -1 day"));
return array($firstday, $nowday, $lastday);
}