try { var q = "nnhl,nnhl-wharnsby"; z = q.split(","); for (i=0; i < z.length ;i++) { var $e = document.getElementById(z[i]); $e.className += " active"; if ($e.getElementsByTagName("ul").length > 0) { var sportsNav = document.getElementsByClassName('sports-nav'); sportsNav.length ? sportsNav[0].className += " active" : $e.parentNode.className += " active"; } } try { var title = document.getElementById(z[z.length-1]).getElementsByTagName("a")[0].attributes.getNamedItem("title").nodeValue; if (title && title != ""){ document.getElementById('sectionid').innerHTML = title; }else{ document.getElementById('masthead').className += " hidepipe"; } }catch(e){} }catch(e){}