Skip to content

Instantly share code, notes, and snippets.

@bdanin
Last active September 20, 2020 21:27
Show Gist options
  • Save bdanin/dc89d595b843a83a57bd4c4db757ac28 to your computer and use it in GitHub Desktop.
Save bdanin/dc89d595b843a83a57bd4c4db757ac28 to your computer and use it in GitHub Desktop.
HTML for the WordPress site, PlaneteerMovement.com
<!-- Moment JS CDN link. -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.28.0/moment.min.js"></script>
<!-- Custom jQuery. -->
<script>
$ = jQuery.noConflict();
const now = new Date();
const days = ['Sunday','Monday','Tuesday','Wednesday','Thursday','Friday','Saturday'];
const months = ['January','February','March','April','May','June','July','August','September','October','November','December'];
callTimeOffset = moment().format("Z");
</script>
<!-- First Call HTML and JS. -->
<h3>First Call — <time class="zoom-time__first" data-datetime-first="9/22/2020 2:00:00 PM UTC">14:00 GMT</time></h3>
<p>Local Time:<br><span id="time--first"></span></p>
<script>
$( document ).ready(function() {
let callTimeFirst = $(".zoom-time__first").data("datetimeFirst");
callTimeFirst = new Date(callTimeFirst);
callTimeFirstHours = callTimeFirst.getHours();
callTimeFirstDay = days[callTimeFirst.getDay()];
callTimeFirstMonth = months[callTimeFirst.getMonth()];
callTimeFirstDate = callTimeFirst.getDate();
printedCallTime = callTimeFirstDay + ", " + callTimeFirstMonth + " " + callTimeFirstDate + "; " + callTimeFirstHours + ":00 (GMT: " + callTimeOffset + ")";
document.getElementById("time--first").innerHTML = printedCallTime;
});
</script>
<!-- Spacer and Link Button. -->
<div style="height:25px" aria-hidden="true" class="wp-block-spacer"></div>
<p>
<em>Link will be posted prior to the call.</em>
<!-- <a target="_blank" href="https://us02web.zoom.us/j/89320552446" rel="noreferrer noopener" class="wp-block-button__link">Join Zoom Call:<br>893 2055 2446</a> -->
</p>
<!-- Second Call HTML and JS. -->
<h3 class="has-text-align-right">Second Call — <time class="zoom-time__second" data-datetime-second="9/22/2020 5:00:00 AM UTC">05:00 GMT</time></h3>
<p class="has-text-align-right">Local Time:<br><span id="time--second"></span></p>
<script>
$( document ).ready(function() {
let callTimeSecond = $(".zoom-time__second").data("datetimeSecond");
callTimeSecond = new Date(callTimeSecond);
callTimeSecondHours = callTimeSecond.getHours();
callTimeSecondDay = days[callTimeSecond.getDay()];
callTimeSecondMonth = months[callTimeSecond.getMonth()];
callTimeSecondDate = callTimeSecond.getDate();
printedCallTime = callTimeSecondDay + ", " + callTimeSecondMonth + " " + callTimeSecondDate + "; " + callTimeSecondHours + ":00 (GMT: " + callTimeOffset + ")";
document.getElementById("time--second").innerHTML = printedCallTime;
});
</script>
<!-- Spacer and Link Button. -->
<div style="height:25px" aria-hidden="true" class="wp-block-spacer"></div>
<p class="has-text-align-right">
<em>Link will be posted prior to the call.</em>
<!-- <a target="_blank" href="https://us02web.zoom.us/j/83786682701" rel="noreferrer noopener" class="wp-block-button__link alignright">Join Zoom Call:<br>837 8668 2701</a> -->
</p>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment