I have below JavaScript Code. It not getting called when page is loaded. Even Alert is not displaying; moment.min.js is placed in same folder..
<script type='text/javascript' src="moment.min.js">
alert("Testing Hello...")
var mysql_date = '2013-01-25 10:00:00';
var date = moment(mysql_date , 'YYYY-MM-DD HH:mm:ss'); // new moment.js object.
// To display the date in a different format use:
var date_format1 = date.format('MMM, Do'); // Format here would be Jan, 25th
var date_format2 = date.format('MMMM, Do, YYYY'); // January, 25th, 2013
alert(date_format1);
alert(date_format2);
console.log(date_format1, date_format2);
</script>
Please let me know why this script is not loaded when page is loaded
srcon a script tag, as well as including code within. It works, but it is debatable whether or not it will continue to work in the future.