Please try following code
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Untitled Document</title>
<script type="text/javascript">
var d = new Date();
var monthname = new Array("January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December");
//Ensure correct for language. English is "January 1, 2004"
var TODAY = monthname[d.getMonth()] + " " + d.getDate() + ", " + d.getFullYear();
function today()
{
document.getElementById('txtBox').value = TODAY.toString();
return false;
}
</script>
</head>
<body>
<form>
<input type="text" name="txtBox" id="txtBox">
<input type="button" value="Today" onclick="return today()">
</form>
</body>
</html>