Skip to content

Get The Difference Between Two Dates #9

@natedrake

Description

@natedrake

In the Date.php class define a method to get the difference of two dates in whatever format the user needed them in.

E.g.

Date::differenceInDates($date1, $date2);

returns in ms by default, but 3rd param could be supplied to change return format

Date::differenceInDates($date1, $date2, 's');

returns difference in seconds

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions