I've been working on a time app for JS and I was wondering, how could I change the time zone. See, I live in the eastern time zone of North America, and i don't like converting it to the International Timezone. So here is my Code.
onclick="document.getElementById('time').innerHTML = Date()">
Click me to display Date and Time.</button>
Wed Dec 30 2015 13:40:25 GMT+0000 (UTC)
Date.prototype.toString is supposed to give you a string in your local time (as configured on your client).
When you click
Run code snippet this should show an alert dialog with your local time string (
toString is implicitly called, like in your example);
If it does give you the expected result then either you client timezone is not configured correctly or the browser you are using is bugged.