I am just wondering how I can compare a date with the following code:
var today = new Date();
Outputs the current day like so:
Wed Feb 24 2016 12:02:34 GMT+0000 (GMT Standard Time)
However if I have a variable containing a string like so:
var end = "Tue Mar 1 2016 00.00.00 GMT+0000 (GMT Standard Time)";
I am unable to compare these two variables in an if statement using the greater than operator because the end
variable is a string.
So I am just wondering how I can compare a set date in a variable with my today variable?
Thanks, Nick