document.getElementsByTagName('font')[1].style.display = "none";
document.getElementsByTagName('table')[0].style.cssText = 'margin-top: -15px; width: 100%;';

/*
* Quantum Skin
* Design By Oracle
* Coded By Dregond Rahl
**/

var table = document.getElementsByTagName('table');
var td = document.getElementsByTagName('td');

var oracle = {

	init: function() {

		this.mouse_over();
		this.create_elem();
		this.copy_right();
	},

	create_elem: function() {

		main_tab = document.createElement('table');
		base_img = document.createElement('div');
		main_row = document.createElement('tr');
		cell_1 = document.createElement('td');
		cell_2 = document.createElement('td');
		link_pm = document.createElement('a');
	},

	mouse_over: function() {

		for(i = 0; i < document.images.length; i ++){
			if(document.images[i].src.match(/_o(n|ff)/)){

				var pre = new Image();
				pre.src = document.images[i].src.replace("_off", "_on");

				document.images[i].onmouseover = function(){ this.src = this.src.replace("_off", "_on"); };
				document.images[i].onmouseout  = function(){ this.src = this.src.replace("_on", "_off"); };
			}
		}
	},

	remv_mark: function() {

		document.write('<\/div><\/center>');

		if(location.href.match(/action=home/i) || !location.href.match(/(action|board)=/i)){
			for (i = td.length-5; i > 0; i --) {
				if(td[i].className == 'catbg' && td[i].colSpan == '5' && td[i].innerHTML.match(/Mark All Boards Read/i)){
					td[i].parentNode.style.display = 'none';
					break;
				}
			}
		}
	},

	copy_right: function() {

		window.onload = function(){
			document.body.appendChild(document.getElementById("copy"));
       			 document.getElementById("copy").style.display = "block";
		}
	},

	all_base: function() {

		base_img.className = "allBase";

		for(i = 4; i < table.length; i ++){
			if(table[i].className == 'bordercolor' && table[i].cellPadding == '0'){
				table[i].parentNode.insertBefore(base_img.cloneNode(true), table[i].nextSibling);
			}
		}
	},

	pm_link: function() {

		td.item(2).innerHTML.match(/ (\d+) (are|is) new./)

		link_data = (RegExp.$1 != '0')? RegExp.$1 + ' New Private Message' + ((RegExp.$2 == 'are')? 's' : '') : 'No New Private Messages';
		link_pm.appendChild(document.createTextNode(link_data));
		link_pm.href = "?action=pm";

	},

	pm_Info: function() {

		if(pb_username != 'Guest') {
			for(i = 0; i < td.length; i ++) {
				if(td[i].width == '100%' && td[i].vAlign == 'top' && td[i].parentNode.parentNode.parentNode.className == '') {

					main_tab.appendChild(document.createElement('tbody'));

					while(td[i].firstChild.nextSibling.nodeName.match(/^(a|br|font|#text)$/i)) {
						cell_1.appendChild(td[i].firstChild.nextSibling);
					}

					cell_1.style.cssText = "width: 60%;";
					cell_2.style.cssText = "width: 40%; text-align: right; vertical-align: bottom;";
					cell_2.appendChild(link_pm);

					main_row.appendChild(cell_1);
					main_row.appendChild(cell_2);

					main_tab.style.cssText = "width: 100%;";
					main_tab.firstChild.appendChild(main_row);

					td[i].replaceChild(main_tab, td[i].firstChild)
					break;
				}
			}
		}
	}
}; 

oracle.init();


document.write('<center><div style="width: 800px !important;"><span align="center" id="copy" onclick="location.href=\'http://smangii.proboards78.com/index.cgi\'"></span>');