|
split2
Jan 19, 2012 20:55:11 GMT -4
Post by MonsterControl on Jan 19, 2012 20:55:11 GMT -4
<style type='text/css'> .headimage{ text-align: center; } .headimage font{ color: #F1F1F1; } </style>
<script type='text/javascript'> /* Tri-Image Category Splitter by Scorpian Copyright (c)2006 Roddy Innovations Designs Version 1 ~ [url]http://roddyinnovations.com[/url] */
/*=== Edit These ===*/ var hImg = 'URL_OF_HEAD_IMAGE.gif'; // The url of your head image var hHeight = '25'; // The height of the head image
var cImg = 'URL_OF_CENTER_IMAGE.gif'; // The url of the image the boards will be overlayed on
var bImg = 'URL_OF_BASE_IMAGE.gif'; // The url of your base image var bHeight = '10'; // The height of your base image
var sWidth = '90%'; // The width of the overlayed table var gHeight = '20'; // The height of the gap between the categories
var hCat = 'no'; // Show the category text on the head image? 'yes' or 'no'. var fNrow = 'yes'; // Show the forum name row? 'yes' or 'no'. var mArRow = 'yes'; // Show the mark as read bar? 'yes' or 'no'.
/*=== Do Not Edit ===*/ if(location.href.match(/action=home$/i) || !location.href.match(/(action|board)=/i)){ document.write("<script type='text/javascript' src='http://roddyinnovations.com/pbhacks/trisplitter.js'></scr" + "ipt>"); } </script>
|
|
|
split2
Jan 19, 2012 21:00:07 GMT -4
Post by MonsterControl on Jan 19, 2012 21:00:07 GMT -4
lol
<script type='text/javascript'> /* Post Splitter with Head/Base images v2 By Scorpian: [url]http://roddyinnovations.com[/url] */
/*/_| Edit These |_\*/ var riHead = 'URL_OF_HEAD_IMAGE'; // URL of head image var riBase = 'URL_OF_BASE_IMAGE'; // URL of base image var riGap = '25'; // Height of gap var riAuthor = 'yes'; // Show "author|topics" row? 'yes' or 'no' only
/*/_| Do Not Edit |_\*/ var riTable = document.getElementsByTagName('table'); var headImg = document.createElement('img'); var baseImg = document.createElement('img'); headImg.src = riHead; baseImg.src = riBase; var tehTab = document.createElement('table'); var tehBody = document.createElement('tbody'); tehTab.cellSpacing = 1; tehTab.cellPadding = 4; tehTab.className = 'bordercolor'; tehTab.width = '100%'; var gapDiv = document.createElement('div'); gapDiv.style.height = riGap; var end = false; var insBef = false; if(location.href.match(/action=display/i)){ for(a=0; a<riTable.length; a++){ if(riTable[a].cellSpacing == 1 && riTable[a].cellPadding == 4 && riTable[a].rows[0].cells[0].colSpan == 2){ riTable[a-1].style.backgroundColor = 'transparent'; riTable[a].className = 'bordercolor'; var newCell = riTable[a-1].insertRow(-1).insertCell(0); for(b=2; b<riTable[a].rows.length; b++){ if(!insBef){ if(riTable[a].rows[b-1].cells[0].className == "catbg" && riTable[a].rows[b-1].cells[0].innerHTML.match(/>Poll</i)){ var insBef = true; newCell.appendChild(gapDiv.cloneNode(true)); } } if(riTable[a].rows[b].cells[0].className.match(/windowbg/i) && !riTable[a].rows[b-1].cells[0].innerHTML.match(/>Poll</i)){ var newTable = tehTab.cloneNode(true); var newTab = tehBody.cloneNode(true); if(riTable[a].rows[b-1].cells[0].className == 'catbg' && riTable[a].rows[b-2].cells[0].className == 'titlebg'){ newTab.appendChild(riTable[a].rows[b-2].cloneNode(true)); riTable[a].rows[b-2].style.display = 'none'; if(riAuthor == 'yes'){ newTab.appendChild(riTable[a].rows[b-1].cloneNode(true)); } riTable[a].rows[b-1].style.display = 'none'; } if(insBef){ newTab.appendChild(riTable[a].rows[0].cloneNode(true)); riTable[a].rows[0].style.display = 'none'; if(riAuthor == 'yes'){ newTab.appendChild(riTable[a].rows[3].cloneNode(true)); } riTable[a].rows[3].style.display = 'none'; } newTab.appendChild(riTable[a].rows[b].cloneNode(true)); riTable[a].rows[b].style.display = 'none'; if(riTable[a].rows[b+1] && riTable[a].rows[b+1].cells[0].className == 'titlebg'){ var end = true; newTab.appendChild(riTable[a].rows[b+1].cloneNode(true)); riTable[a].rows[b+1].style.display = 'none'; if(riTable[a].rows[b+2]){ newTab.appendChild(riTable[a].rows[b+2].cloneNode(true)); riTable[a].rows[b+2].style.display = 'none'; } } newCell.appendChild(headImg.cloneNode(true)); newTable.appendChild(newTab); newCell.appendChild(newTable); newCell.appendChild(baseImg.cloneNode(true)); if(!end){ newCell.appendChild(gapDiv.cloneNode(true)); } } } if(insBef){ riTable[a].parentNode.insertBefore(headImg.cloneNode(true),riTable[a]); riTable[a].parentNode.insertBefore(baseImg.cloneNode(true),riTable[a].nextSibling); }else{ riTable[a].parentNode.parentNode.style.display = 'none'; } break; } } } </script>
|
|
|
split2
Jan 19, 2012 21:00:47 GMT -4
Post by MonsterControl on Jan 19, 2012 21:00:47 GMT -4
cool
|
|
|
split2
Jan 19, 2012 21:07:51 GMT -4
Post by MonsterControl on Jan 19, 2012 21:07:51 GMT -4
image resize
<script type="text/javascript"> <!-- /*Convert oversized images to links, Created By Chantry Cargill*/ // Max Size of Posted Image var yourwidth = 500; // Text to be displayed for the link in place of the image var linktext = "This is the link"; var td = document.getElementsByTagName("td"); for(var loop = 0;loop<td.length;loop++){ if(td[loop].colSpan=="3" && td[loop].firstChild.nodeName.match(/hr/i) && td[loop].vAlign=="top"){ for(var t=0;t<td[loop].childNodes[1].childNodes.length;t++){ if(td[loop].childNodes[1].childNodes[t].nodeName.match(/img/i)){ var width = td[loop].childNodes[1].childNodes[t].width; if(width>yourwidth){ var news = document.createElement("a"); news.href = td[loop].childNodes[1].childNodes[t].src; news.innerHTML = linktext; td[loop].childNodes[1].replaceChild(news,td[loop].childNodes[1].childNodes[t]); }}}}} //--> </script>
|
|
|
split2
Jan 19, 2012 21:57:14 GMT -4
Post by MonsterControl on Jan 19, 2012 21:57:14 GMT -4
<script type="text/javascript"> <!--
// Created by PopThosePringles
// Set gap size here var iGapSize = 25;
// Head image url var iHeadImg = "URL";
// Base image url var iBaseImg = "URL";
function bTable(tbobj, att){ var nTable = document.createElement("table");
for(a = 0; a < att.length; a ++){ nTable.setAttribute(att[a][0], att[a][1]); } nTable.appendChild(tbobj); return nTable; }
function splitPosts(){ var obj = new Object(); var gPoll = false; var iInc = 0, cInc = 0, oInc = 0; var attArray = [["width", "100%"], ["cellSpacing", 1], ["cellPadding", 4]]; var docFragment = document.createDocumentFragment(); var iTable = document.getElementsByTagName("table");
for(t = 0; t < iTable.length; t ++){ if(iTable.item(t).cellPadding == "4" && iTable.item(t).cellSpacing == "1"){ var iRows = iTable.item(t).rows; for(r = 0; r < iRows.length; r ++){ r = (r < 0)? 0 : r; var nTb = document.createElement("tbody"); var rNode = iRows.item(r); if(rNode && rNode.firstChild.colSpan == "2" && rNode.firstChild.className == "titlebg" && r == 0){ nTb.appendChild(rNode); obj[(iInc ++)] = { tobj: bTable(nTb, attArray) }; r --; } if(rNode && rNode.firstChild.width == "20%" && rNode.innerHTML.match(/>Poll Question: /)){ gPoll = true; nTb.appendChild(rNode); obj[(iInc ++)] = { tobj: bTable(nTb, attArray) }; r --; oInc ++; } if(rNode && rNode.firstChild.colSpan == "2" && rNode.firstChild.className == "windowbg2"){ // lets nest that form correctly so people can vote if(rNode.firstChild.getElementsByTagName("form").item(0) && !document.all){ var pForm = rNode.firstChild.getElementsByTagName("form").item(0); var fNode = pForm.cloneNode(false); pForm.parentNode.removeChild(pForm); while(rNode.firstChild.hasChildNodes()){ pForm.appendChild(rNode.firstChild.childNodes.item(0)); } rNode.firstChild.appendChild(pForm); } obj[(iInc - 1)].tobj.firstChild.appendChild(rNode); r --; oInc ++; } if(rNode && rNode.firstChild.className == "catbg" && rNode.firstChild.innerHTML.match(/Author/)){ nTb.appendChild(rNode); obj[(iInc ++)] = { tobj: bTable(nTb, attArray) }; r --; } if(rNode && rNode.firstChild.width == "20%" && rNode.firstChild.className.match(/^windowbg/i) && rNode.firstChild.innerHTML.match(/member is|guest/i)){ if(cInc == 0){ obj[(iInc - 1)].tobj.firstChild.appendChild(rNode); r --; } else { nTb.appendChild(rNode); obj[(iInc ++)] = { tobj: bTable(nTb, attArray) }; } cInc ++; r --; oInc ++; } } iTable.item(t).parentNode.parentNode.parentNode.id = "marker"; } }
function createImg(url){ var iImg = document.createElement("img");
iImg.src = url; return iImg; }
var iCount = 0; for(var o in obj){ var hDiv = document.createElement("div"); var nDiv = document.createElement("div");
hDiv.style.height = iGapSize; nDiv.className = "bordercolor"; nDiv.style.width = "100%";
oInc -= (gPoll)? 1 : 0; gPoll = false; if(o > 0 && o <= oInc){ nDiv.appendChild(createImg(iHeadImg)); }
nDiv.appendChild(obj[o].tobj);
if(o > 0 && o <= oInc){ nDiv.appendChild(createImg(iBaseImg)); } if(iCount > 0){ docFragment.appendChild(hDiv); } docFragment.appendChild(nDiv); iCount ++; } if(document.getElementById("marker")){ var iMarker = document.getElementById("marker"); iMarker.parentNode.parentNode.insertBefore(docFragment, iMarker.parentNode); } }
if(location.href.match(/action=display/i)){ splitPosts(); }
//--> </script>
|
|
|
split2
Jan 19, 2012 22:38:36 GMT -4
Post by MonsterControl on Jan 19, 2012 22:38:36 GMT -4
<script type="text/javascript"> <!--
// Created by PopThosePringles
// Size of the gap between categories var gapSize = 25;
var tabHTML = '<td id="rr" colspan="5"></table></td></tr></table><div style="height:' + gapSize + '"></div><table width="100%" cellspacing="0" cellpadding="0" class="bordercolor"><tr><td><table cellpadding="4" cellspacing="1" width="100%"><tr>';
if(location.href.match(/\.com(\/|.+cgi(\?|#.+|\?\w+=home)?)?$/i)){ var tBod = document.getElementsByTagName("tbody"); for(tb = 0; tb < tBod.length; tb ++){ for(r = 2; r < tBod.item(tb).rows.length; r ++){ var tBodObj = tBod.item(tb).rows.item(r).cells.item(0); if(tBodObj.className == "catbg" && tBodObj.colSpan == "5" && tBodObj.align != "right"){ var c = tabHTML + tBod.item(tb).firstChild.innerHTML + "</tr>"; var p = tBodObj.parentNode.innerHTML; var tBodPar = tBod.item(tb).parentNode.parentNode.parentNode.parentNode.parentNode; tBodPar.parentNode.innerHTML = tBodPar.parentNode.innerHTML.replace(p, c + p); } if(tBod.item(tb).rows.item(r).firstChild.id == "rr"){ tBod.item(tb).rows.item(r).style.display = "none"; } } } }
//--> </script>
|
|
|
split2
Jan 19, 2012 22:39:46 GMT -4
Post by MonsterControl on Jan 19, 2012 22:39:46 GMT -4
<script type="text/javascript"> <!--
// Created by PopThosePringles
// Head image and height var iHeadImg = "URL"; var iHeadHeight = 25;
// Base image and height var iBaseImg = "URL"; var iBaseHeight = 25;
var iTable = document.getElementsByTagName("table");
function doHeadBase(){ for(t = 0; t < iTable.length; t ++){ if(iTable.item(t).width == "100%" && iTable.item(t).cellPadding == "0" && iTable.item(t).innerHTML.match(/Forum Name|Info Center|Stay logged in for:/)){ var hCell = iTable.item(t).insertRow(0).insertCell(0) hCell.colSpan = 5; hCell.height = iHeadHeight; hCell.style.backgroundImage = "url('" + iHeadImg + "')"; var bCell = iTable.item(t).insertRow(iTable.item(t).rows.length).insertCell(0); bCell.colSpan = 5; bCell.height = iBaseHeight; bCell.style.backgroundImage = "url('" + iBaseImg + "')"; } } }
if(location.href.match(/\.com(\/|.+cgi(\?|#.+|\?\w+=home)?)?$/i)){ doHeadBase(); }
//--> </script>
|
|