var fileNum = 44;
var URLTestimonialPath = 'http://' + location.host + '/testimonial/';

function getTestimonial() {
  var randomNum = Math.random() * fileNum + 1; // add 1 to increment the base of zero
  var randomFile = URLTestimonialPath + Math.floor(randomNum) + '.htm';
  AjaxRequest.get(
    {
      'url':randomFile,
      'onSuccess':function(req){ document.getElementById('TestimonialDiv').innerHTML = (req.responseText); }
    }
  );
}

function externalLinks() {
  if (!document.getElementsByTagName) return;
  var anchors = document.getElementsByTagName("a");
  for (var i=0; i<anchors.length; i++) {
    var anchor = anchors[i];
    if (anchor.getAttribute("href") &&
    anchor.getAttribute("rel") == "newWindow")
    anchor.target = "_blank";
  }
}
