<!DOCTYPE html>
<html>
<head>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script>
<script>
$(document).ready(function(){
var invDates = new Date();
var month = invDates.getMonth() + 1;
invDates.setDate(15);
var year = invDates.getFullYear();
var formatDate =month + '/' +
invDates.getDate()+ '/' +
year;
var newdate= new Date(formatDate);
alert(formatDate )
alert(newdate)
});
</script>
</head>
<body>
<div id='test'></div>
</body>
</html>