// Only links written to the page (already in the DOM) will be tagged
// Script can be called multiple times
function addExtLinkerEvents() {
	var as = document.getElementsByTagName("a");
	var extTrack = ["shop-round.ru"];

	for (var i = 0; i < as.length; i++) {
		var tmp = as[i].getAttribute("onclick");
		// Track links off site – i.e. no GATC
		if (tmp != null && tmp.indexOf('urchinTracker') > -1)
			continue;
		for (var j = 0; j < extTrack.length; j++) {
			if (as[i].href.indexOf(extTrack[j]) == -1) {
				var splitResult = as[i].href.split("//");
				as[i].setAttribute(
					"onclick",((tmp != null) ? tmp : "")
					+ "urchinTracker('/ext/" + splitResult[1]+ "');"
				);
				// the above must be on one line - from as[i]... to ");
				break;
			}
		}
	}
}