diff --git a/clock.js b/clock.js index b58802c..199b124 100644 --- a/clock.js +++ b/clock.js @@ -32,7 +32,8 @@ function startTime(){ hour:'2-digit', minute:'2-digit', second:'2-digit',}); - if(original_tz){//Test if there is a non-null value for original_tz. If True then the part of the page this pertains to is being displayed. + if(display_origTZ){//Test if there is a non-null value for original_tz. If True then the part of the page this pertains to is being displayed. + //~ alert("display_origTZ == " + display_origTZ); document.getElementById('time_original').innerHTML = current_time.toLocaleString('en-EN' ,{ timeZone: original_tz, hourCycle:'h24', diff --git a/clock.php b/clock.php index 2420058..48af5f7 100644 --- a/clock.php +++ b/clock.php @@ -15,6 +15,9 @@ $scriptHour = date('O'); $scriptTZ = date_default_timezone_get(); } + if($_POST['originalTZ']){ + $orig_TZ_display = True; + } } else{ $selectedTimezone = date_default_timezone_get(); $scriptTZ = date_default_timezone_get(); @@ -32,7 +35,7 @@ - +