have a look at strtotime()
this function returns a timestamp to the coressponding timestring,
hence get the difference between those two timestamps, which
is now the diff in seconds, divide the rest (% modulo may be of help)
to get days, hours ...
$diff_in_sec = abs(strtotime($time1)-strtotime($time2));
...
to find out if a date has passed, compare its timestamp with the
one time() returns, if the 2st one is bigger, it's still to come
if (strtotime($time) < time()) echo "passed";
else echo "still 2come";