text: window.onload = function() {
  
      function addClass(element, className) {
          element.className += " " + className;
      }
  
      function removeClass(element, className) {
          // Capture any surrounding space characters to prevent repeated
          // additions and removals from leaving lots of spaces.
          var classNameRegEx = new RegExp("\\s*" + className + "\\s*");
          element.className = element.className.replace(classNameRegEx, " ");
      }
  
      function toggleClass(element, className) {
          if (!element || !className) {
              return;
          }
  
          if (element.className.indexOf(className) === -1) {
              addClass(element, className);
          } else {
              removeClass(element, className);
          }
      }
  
      // Open Twitter/share in a Pop-Up
      var $popup = document.getElementsByClassName('popup')[0];
      if (!$popup) {
          return;
      }
      $popup.addEventListener('click', function(e) {
          e.preventDefault()
          var width  = 575,
              height = 400,
              left   = (document.documentElement.clientWidth  - width)  / 2,
              top    = (document.documentElement.clientHeight - height) / 2,
              url    = this.href,
              opts   = 'status=1' +
                       ',width='  + width  +
                       ',height=' + height +
                       ',top='    + top    +
                       ',left='   + left;
  
          window.open(url, 'twitter', opts);
  
          return false;
      });
  }
  