"); $("#footer-address .sitename").append('' + siteNameArray[1] + ''); } }; var siteNameOne = jQuery.trim('Chief Joseph'); var siteNameTwo = jQuery.trim('School of the Arts'); if((siteNameOne == "") && (siteNameTwo == "")) { var splitLen = 2; var siteName = "Chief Joseph School of the Arts"; siteName = siteName.split(" "); var siteNameLength = siteName.length; if(siteNameLength > 2){ siteNameEnd = jQuery.trim(siteName.splice(-splitLen, siteName.length).toString().replace(/,/g, " ")); } else { siteNameEnd = jQuery.trim(siteName.splice(-1, siteName.length).toString().replace(/,/g, " ")); } siteNameBegin = jQuery.trim(siteName.toString().replace(/,/g, " ")); $("#gb-sitename").prepend("