  var scriptNode = document.getElementById('adScript');
  var pNode = scriptNode.parentNode;
  var cssNode = document.createElement('link');
  cssNode.setAttribute('rel', 'stylesheet');
  cssNode.setAttribute('type', 'text/css');
  cssNode.setAttribute('href', 'http://style.locallinkup.com/449.css');
  pNode.insertBefore(cssNode, scriptNode);
  var adDiv = document.createElement('div');
  adDiv.id = 'lluAdbox';
  adDiv.style.width = '150px';
  adDiv.style.height = '150px';
  adDiv.style.position = 'relative';
  var mainLink = document.createElement('a');
  mainLink.id = 'mainLink';
  mainLink.setAttribute('href', 'http://www.locallinkup.com');
  mainLink.setAttribute('target', '_blank');
  mainLink.innerHTML = 'www.locallinkup.com';
  mainLink.style.overflow = 'hidden';
  adDiv.appendChild(mainLink);
  var adText = document.createElement('div');
  adText.id = 'adText';
  adText.innerHTML = 'www.locallinkup.com';
  adText.style.overflow = 'hidden';
  adDiv.appendChild(adText);
  var subLink = document.createElement('a');
  subLink.id = 'subLink';
  subLink.setAttribute('href', 'http://www.locallinkup.com');
  subLink.setAttribute('target', '_blank');
  subLink.innerHTML = 'Click here to visit';
  adDiv.appendChild(subLink);
  var lluLink = document.createElement('a');
  lluLink.id = 'lluLink';
  lluLink.setAttribute('href', 'http://www.locallinkup.com');
  lluLink.setAttribute('target', '_blank');
  lluLink.innerHTML = 'locallinkup.com';
  adDiv.appendChild(lluLink);
  pNode.insertBefore(adDiv, scriptNode);
  var numAds = 2;
  var switchDelay = 30000;
  var commitDelay = 10000;
  var adverts = new Array();
  var adCounter = 0;
  var timeCounter = switchDelay;
    adverts[0] = "2054720;Bob Dixon;Counselling and Therapy - Lancaster;http://www.locallinkup.com/bob-dixon_lancaster_2054720.html";
    adverts[1] = "2082490;Computer Solutions Lancashire;Low Cost Computer Repairs in Carnforth, Lancashire.;http://www.locallinkup.com/computer-solutions-lancashire_carnforth_2082490.html";
  getAd();
    function getAd() {
      var nextAdvertBits = adverts[adCounter].split(';');
      if (timeCounter == (switchDelay + commitDelay) | timeCounter == ((switchDelay * 2) + commitDelay)) {
        var comScript = document.createElement('script');
        comScript.setAttribute('type', 'text/javascript');
        comScript.setAttribute('src', 'http://link.locallinkup.com/commitServer.ashx?id=' + nextAdvertBits[0] + '&page=' + window.location);
        pNode.insertBefore(comScript, scriptNode);
      }
      if (timeCounter % switchDelay == 0) {
        document.getElementById('mainLink').innerHTML = nextAdvertBits[1];
        document.getElementById('mainLink').href = "http://" + nextAdvertBits[3];
        document.getElementById('adText').innerHTML = nextAdvertBits[2];
        document.getElementById('subLink').href = "http://" + nextAdvertBits[3];
        adCounter++;
      }
      timeCounter += 10000;
      if (adCounter == numAds) {
        adCounter = 0;
      }
      var t = setTimeout('getAd()',10000);
    }
