Check leap year with php

isLeapYear() accepts integer year and returns true if it is a leap year else it returns false.

Continue


Convert minutes to hours with PHP

Function minToHour accepts hours and minutes as parameters and convert it to hours. This is a cool PHP function to convert minutes into hours.

Continue


Get age from date with PHP

getAge() is a custom written function that returns the age from a given date.

Continue


Get dates between 2 dates with PHP

Function getDatesBetween2Dates() returns all dates between 2 dates. you just need to pass 2 date parameters to this function.

Continue


Get day of week from a date

getWeekDay() returns weekday from a date after accepting valid date as argument.

Continue


Get days between two dates with PHP

Function count_days() is designed to calculate the difference between 2 dates. 2 date arguments are can be passed to this function to calculate total number of days between 2 given dates.

Continue


Get Future Date with PHP

With function GetFutureDate(), the date after x number of days can be calculated since a specific date. Just pass a date and an integer argument to this function to see the date.

Continue


Get long date with php

getLongDate() returns long formatted date after accepting date as parameter.

Continue


Get Month Name From Number With PHP

Simply, pass a number value to function getMonth() to get name of the month. For example if you pass 10 to this function then output will be "October".

Continue


Get month name from week number

getMonthFromWeek() returns name of the month after accepting year and week number.

Continue