How to Find Quarter Month From Any Year ?

A Quarter means 1/4 part of year.
In the following example given Script is
use to find which quarter of the year
in the given date.

Assuming given date is 10 December 2015
Following is the Example.
Just Copy & Paste and Enjoy.

$month = 12;
$date = 10;
$year = 2015;
$qm = mktime(0,0,0,$month,$date,$year);
echo ceil(date(“m”, $qm)/3);

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: