Hello World

Sep 26, 2017 | Views 383 | Likes 0 | Comments 30

This is my paragraph....

*hello.php

function get_date($type)
{
	if($type == 'start_date_this_month')
	{
		return date('Y-m-').'01';
	}
	elseif($type == 'start_date_last_month')
	{
		return date('Y-m-', strtotime('-1 month')) .  '01';
	}
	elseif($type == 'end_date_this_month')
	{
		return date('Y-m-t');
	}
	elseif($type == 'end_date_last_month')
	{
		$dt_last_mo = date('Y-m-d', strtotime('-1 month')); // date of last month
		return date('Y-m-t', strtotime($dt_last_mo));
	}
}

 


10 Comments
2017-04-05 13:44:13
Katie
Thanks for the post. It works for me!


2017-10-18 18:17:56
test
test


2017-10-18 18:19:08
test
test


2017-10-21 18:44:36
e
test


2017-07-03 06:59:51
Bryan
Can you add the class and extend this?


2017-10-01 15:35:21
JaneLk
I agreed with you.


2017-10-06 22:34:24
G3838
Small she avoid six yet table china. And bed make say been then dine mrs. To household rapturous fulfilled attempted on so.


2017-10-21 22:06:32
se
test


2017-10-21 22:08:53
asdfsaf
asdfas


2017-10-21 22:17:29
asdf
asdf



Leave a comment