Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<h2>Try this link</h2> <p><strong><a href="http://www.techtricky.com/jquery-code-to-show-time-in-different-countries/" rel="nofollow">http://www.techtricky.com/jquery-code-to-show-time-in-different-countries/</a></strong></p> <p>And the demo is showing the day name in the result.</p> <h1>HTML &amp; JS:</h1> <pre><code>&lt;html&gt; &lt;head&gt; &lt;script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.4/jquery.min.js"&gt;&lt;/script&gt; &lt;script type="text/javascript" src="http://techtricky.com/wp-content/jquery/jquery.jclock.js"&gt;&lt;/script&gt; &lt;script type="text/javascript"&gt; $(document).ready( function() { $("#zones").change(function(){ if ($('#time-cont .time').length&gt;0){ $('#time-cont .time').remove();} var offset = $(this).val(); if (offset == '') return; $('#time-cont').append('&lt;div class="time"&gt;&lt;/div&gt;'); var options = { format:'&lt;span class=\"dt\"&gt;%A, %d %B %I:%M:%S %P&lt;/span&gt;', timeNotation: '12h', am_pm: true, fontFamily: 'Verdana, Times New Roman', fontSize: '20px', foreground: 'black', background: 'yellow', utc:true, utc_offset: offset } $('#time-cont .time').jclock(options); }); }); &lt;/script&gt; &lt;/head&gt; &lt;body&gt; &lt;select id="zones"&gt; &lt;option value=""&gt;--Select--&lt;/option&gt; &lt;option value="10"&gt;Australia&lt;/option&gt; // Australia UTC offset value is 10 &lt;option value="8"&gt;China&lt;/option&gt; &lt;option value="5.5"&gt;India&lt;/option&gt; &lt;option value="12"&gt;Newzealand&lt;/option&gt; &lt;option value="0"&gt;UK&lt;/option&gt; &lt;option value="-5"&gt;US EST&lt;/option&gt; &lt;/select&gt; &lt;div id="time-cont"&gt;&lt;/div&gt; &lt;/body&gt; &lt;/html&gt; </code></pre>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload