inherit
134992
0
May 26, 2012 2:38:57 GMT -8
SubDevo
Creator of LSD...
3,861
December 2008
subdevo
|
Post by SubDevo on Jun 23, 2010 2:19:39 GMT -8
Image Cell Highlight for Individual Boards by SubDevoTested in IE, FF, Opera, Safari and Chrome. This code allows you to have a different image cell highlight for individual boards on the main page. This also works for sub-boards too! Enjoy!!! SubDevo Variables: Edit the Maroon portions. Brd_Imgs["general"]= "URL TO IMAGE";Enter the Board ID in the first Maroon part, and the URL to the hover image in the second part. To add more boards, simply copy/paste this line and change the board ID and URL to the image. The board ID is what follows "board=" in the address bar. http://interoceandesigns.com/index.cgi?board=proboardcodedatabase&action=display&thread=1376Location: Global Footer<script type="text/javascript"> /* Image Cell Highlight for Individual Boards by SubDevo */ /* Global Footer - Please leave this header intact. Do not repost. */ /* interoceandesigns.com or lsdp.proboards.com */
var Brd_Imgs=[]; // DO NOT TOUCH // format: Brd_Imgs["BOARD ID"]= "URL TO IMAGE"; Brd_Imgs["general"]= "URL TO IMAGE";
if(/^(home|boardindex)$/i.test(pb_action)&& !/=newestthreads$/.test(location.href)){ var td=document.getElementsByTagName("td"),n,b,x=-1; while(td[++x]){ b=td[x]; if(b.width=="66%"&&b.onclick&&/board=(.+?)\"/i.test(b.innerHTML)){ if(Brd_Imgs[RegExp.$1]){ b.onmouseout=function(){this.style.backgroundImage="";} b.onmouseover=function(){var n=(/board=(.+?)\"/i.test(this.innerHTML))?RegExp.$1:""; if(Brd_Imgs[n]){this.style.backgroundImage="url("+Brd_Imgs[n]+")";}} }}}} </script>EDIT: 8/24/2011 Code updated to be smaller and more efficient.
|
|