Javascript new Date() giving different outputs for different timezones : <p>I have below code in my function</p>

<pre><code>alert(date);
var result = new Date(date);      
alert(result);
</code></pre>

<p>Output as below</p>

<p>When I set my system time as India</p>

<pre><code>2017-11-07
Tue Nov 07 2017 05:30:00 GMT+0530 (India Standard Time)
</code></pre>

<p>When I set my System timezone as US &amp; Canada</p>

<pre><code>2017-11-07
Mon Nov 06 2017 18:00:00 GMT-0600 (Central Standard Time)
</code></pre>

<p>What is the issue here and how can I fix this?</p>
