i want to compare two dates. i used this code
function addRow(dateval,bidchekval) {                       
    var val1 = document.getElementById(dateval);            
   var valcheck=document.getElementById(bidchekval).value;
   var val123=document.getElementById(dateval).value;
   if(val123 > valcheck ){
       alert("success");
   }
}
This is the code that i used but when change month then it will break.those two dates get using date picker. date format example:06-12-2013 15:12:15
 
     
    