I want to add a day to date I get from textbox.I tried the code below but it did not work
    function get_renew_date ()
    {
        var chkautorenew=document.getElementById("MainContent_chk_Isauto_Renew");
        if (chkautorenew.checked) {
            end_date = document.getElementById("MainContent_txtContract_End_date").value;
            renew_date = document.getElementById("MainContent_txtContract_Renew").value;
            dat = new Date(end_date.toDateString());
            //renew_date=dat.addDays(1);
            alert(end_date.toDateString());
        }
     }
I'm also worried about the client date format and the last day of the month, how can I be sure that after adding a day it will not be like this 32/03/2016
thank you
 
     
     
    