Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

autoboot

  • Loading branch information...
commit 75eb8a780fa14388316cbbcc2da9c05d7595f737 1 parent 61b035e
Michael Deal mudcube authored

Showing 1 changed file with 20 additions and 1 deletion. Show diff stats Hide diff stats

  1. +20 1 hire-us/hire-us.js
21 hire-us/hire-us.js
@@ -24,6 +24,13 @@ var HireUs = {};
24 24 "<a href=\"mailto:connect@whatislucent.com\" class=\"hire-contact\"><span class=\"hire-inner\"></span></a>",
25 25
26 26 init: function(placement) {
  27 + var head = document.getElementsByTagName("head")[0];
  28 + var css = document.createElement("link");
  29 + css.rel = "stylesheet";
  30 + css.type = "text/css";
  31 + css.media = "screen";
  32 + css.href = "/media/hire-us/hire-us.css";
  33 + head.appendChild(css);
27 34 placement = (typeof placement !== 'undefined') ? placement : 'tl';
28 35 // insert link into page
29 36 var link = document.createElement('a');
@@ -58,7 +65,19 @@ var HireUs = {};
58 65 event.cancelBubble = true;
59 66 }
60 67 return root;
  68 + },
  69 +
  70 + boot: function() {
  71 + HireUs.init('tr');
61 72 }
62 73 }
63 74
64   -})();
  75 +})();
  76 +
  77 +if (typeof window.addEventListener != 'undefined') {
  78 + window.addEventListener('load', HireUs.boot, false);
  79 +} else if(typeof document.addEventListener != 'undefined') {
  80 + document.addEventListener('load', HireUs.boot, false);
  81 +} else if(typeof window.attachEvent != 'undefined') {
  82 + window.attachEvent('onload', HireUs.boot);
  83 +}

0 comments on commit 75eb8a7

Please sign in to comment.
Something went wrong with that request. Please try again.