myOpenNav();
document.getElementById("btnNavOpen").addEventListener("click", function(){myOpenNav();});
var liab = document.getElementById("btnLiab");
if (liab) {
document.getElementById("btnLiab").addEventListener("mouseover", function(){myHighlightFunction("row3");});
};
document.getElementById("btn1").addEventListener("mouseover", function(){myHighlightFunction("row1");});
document.getElementById("btn2").addEventListener("mouseover", function(){myHighlightFunction("row2");});
document.getElementById("btn3").addEventListener("mouseover", function(){myHighlightFunction("row3");});
document.getElementById("btn4").addEventListener("mouseover", function(){myHighlightFunction("row4");});
document.getElementById("btn5").addEventListener("mouseover", function(){myHighlightFunction("row5");});
document.getElementById("btn6").addEventListener("mouseover", function(){myHighlightFunction("row6");});
document.getElementById("btn7").addEventListener("mouseover", function(){myHighlightFunction("row7");});
document.getElementById("btn8").addEventListener("mouseover", function(){myHighlightFunction("row8");});
document.getElementById("btn9").addEventListener("mouseover", function(){myHighlightFunction("row9");});
document.getElementById("btn10").addEventListener("mouseover", function(){myHighlightFunction("row10");});
document.getElementById("btn11").addEventListener("mouseover", function(){myHighlightFunction("row11");});
document.getElementById("btn12").addEventListener("mouseover", function(){myHighlightFunction("row12");});
document.getElementById("btn13").addEventListener("mouseover", function(){myHighlightFunction("row13");});
document.getElementById("btn14").addEventListener("mouseover", function(){myHighlightFunction("row14");});
document.getElementById("btn15").addEventListener("mouseover", function(){myHighlightFunction("row15");});
document.getElementById("btn16").addEventListener("mouseover", function(){myHighlightFunction("row16");});
document.getElementById("btn17").addEventListener("mouseover", function(){myHighlightFunction("row17");});
document.getElementById("btn18").addEventListener("mouseover", function(){myHighlightFunction("row18");});
document.getElementById("btn19").addEventListener("mouseover", function(){myHighlightFunction("row19");});
document.getElementById("btn20").addEventListener("mouseover", function(){myHighlightFunction("row20");});
document.getElementById("btn21").addEventListener("mouseover", function(){myHighlightFunction("row21");});
document.getElementById("btn22").addEventListener("mouseover", function(){myHighlightFunction("row22");});
document.getElementById("btn23").addEventListener("mouseover", function(){myHighlightFunction("row23");});
document.getElementById("btn24").addEventListener("mouseover", function(){myHighlightFunction("row24");});
document.getElementById("btn25").addEventListener("mouseover", function(){myHighlightFunction("row25");});
function myHighlightFunction(strID) {
myHighlightReset();
document.getElementById(strID).className = "ic-highlight";
};
function myHighlightReset() {
var i;
for (i = 1; i < 26; i++) {
var e1 = "row";
var e2 = e1.concat(i);
var element = document.getElementById(e2);
if (element) {
document.getElementById(e2).className = "";
};
};
};
function myUserID() {
document.getElementsByClassName("username")[0].setAttribute("id", "uncOnyen");
var userID = document.getElementById("uncOnyen").innerHTML;
alert(userID);
};
function setNav(strID) {
document.getElementsByClassName("menu-boilerplate")[0].setAttribute("id", "navGuide");
document.getElementById("navGuide").innerHTML = "Guidance";
document.getElementsByClassName("menu-equipment")[0].setAttribute("id", "navPrefer");
document.getElementById("navPrefer").innerHTML = "Preferred Clauses";
document.getElementsByClassName("menu-insurance")[0].setAttribute("id", "navFreq");
document.getElementById("navFreq").innerHTML = "Frequently Encountered Clauses";
document.getElementsByClassName("menu-miscellaneous")[0].setAttribute("id", "navCaution");
document.getElementById("navCaution").innerHTML = "Cautions";
document.getElementsByClassName("menu-publication")[0].setAttribute("id", "navFifth");
if (strID == "budget-and-payment-terms") {
document.getElementById("navFifth").innerHTML = "Supplemental Information";
} else if (strID == "equipment") {
document.getElementById("navFifth").innerHTML = "Instruction Sheet";
} else {
document.getElementById("navFifth").style.display = "none";
};
};
function updateNav() {
document.getElementById("nav").style.display = "block";
document.getElementById("nav").style.zIndex = "1000";
document.getElementById("nav").style.position = "fixed";
document.getElementById("nav").style.top = "0";
document.getElementById("nav").style.width = "100%";
var adminBar = document.getElementById("wpadminbar");
if (adminBar) {
document.getElementById("wpadminbar").style.display = "none";
};
var uncBar = document.getElementById("unc-ub");
var uncBar1 = document.getElementById("unc-ub-wrapper");
if (uncBar) {
document.getElementById("unc-ub").style.display = "none";
};
if (uncBar1) {
document.getElementById("unc-ub-wrapper").style.display = "none";
};
};
function myOpenNav() {
var addr = window.location.href;
document.body.style.marginLeft = "250px";
document.getElementById("mySideBar").style.width = "250px";
var lnk_policy = window.location.href.split("/")[3];
var lnk_page = window.location.pathname;
sideBarHighlight(lnk_policy);
if (lnk_page == "/") {
document.getElementById("menu-osr-ic-clause-menu").style.display = "none";
};
updateNav();
setNav(lnk_policy);
// myUserID();
};
function sideBarHighlight(strID) {
if (strID == "miscellaneous") {
document.getElementById("side-misc").style.color = "yellow";
} else if (strID == "liability-and-indemnification") {
document.getElementById("side-liab").style.color = "yellow";
} else if (strID == "subject-injury") {
document.getElementById("side-inj").style.color = "yellow";
} else if (strID == "boilerplate") {
document.getElementById("side-boiler").style.color = "yellow";
} else if (strID == "budget-and-payment-terms") {
document.getElementById("side-budget").style.color = "yellow";
} else if (strID == "confidential-information") {
document.getElementById("side-ci").style.color = "yellow";
} else if (strID == "equipment") {
document.getElementById("side-equip").style.color = "yellow";
} else if (strID == "external-parties") {
document.getElementById("side-ext").style.color = "yellow";
} else if (strID == "governing-law-dispute-resolution-remedies") {
document.getElementById("side-gov").style.color = "yellow";
} else if (strID == "inspections-and-monitoring") {
document.getElementById("side-inspect").style.color = "yellow";
} else if (strID == "insurance") {
document.getElementById("side-ins").style.color = "yellow";
} else if (strID == "intellectual-property") {
document.getElementById("side-ip").style.color = "yellow";
} else if (strID == "laws-and-regulations") {
document.getElementById("side-laws").style.color = "yellow";
} else if (strID == "publication") {
document.getElementById("side-pub").style.color = "yellow";
} else if (strID == "study-data-results-and-reporting") {
document.getElementById("side-data").style.color = "yellow";
} else if (strID == "study-personnel") {
document.getElementById("side-pers").style.color = "yellow";
} else if (strID == "subject-privacy") {
document.getElementById("side-priv").style.color = "yellow";
} else if (strID == "subject-safety-reporting-and-aahrpp") {
document.getElementById("side-safe").style.color = "yellow";
} else if (strID == "term-termination-and-survival") {
document.getElementById("side-term").style.color = "yellow";
} else {
document.getElementById("side-home").style.color = "yellow";
};
};