// JS for opening external links in new window

function prepareExternalLinks ()
{
	anchors = document. getElementsByTagName ('a');
	for (var i = 0; i < anchors. length; i++)
	{
		rel = anchors[i]. getAttribute ('rel');
		if (rel == null || rel == 'null')
			continue;

		if (rel. match (/.*external.*/i))
			anchors[i]. setAttribute ('target', '_blank');
	}
}
