var date = new Date();
mydate=new Date('2016-09-13');
if(date < mydate)
{
alert(" The given date is Future Date");
}
else
{
alert("The given date is Past Date");
}
Output :
The given date is Past Date
Algorithm :
First we want to find our current date
To find current date the keyword is new Date()
Initialize the variable for your date to check whether it is current date or not
Comments :