Created
June 28, 2012 17:29
-
-
Save nbashaw/3012692 to your computer and use it in GitHub Desktop.
Hides Olark before 8am and after 5pm Pacific time
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script> | |
// Hide Olark before 8am and after 5pm Pacific time | |
var d = new Date(); | |
var utcHour = d.getUTCHours(); | |
var pacificHour = utcHour - 7; | |
if (pacificHour < 8 || pacificHour > 16) { | |
olark('api.box.hide'); | |
} | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment