Jump to content

Does Firefox center?!


Flameguthix

Recommended Posts

Hey y'all. I'm building a website for a clan on this game called Soldat. Currently, I piggy-backed code from JavaScriptSource.com... just a little scroller that displays text in the field above it. The URL is http://drupal.getalife.us/outclan.htmlIts all div tags and javascript. Lemme just post the CSS/JavaScript and the actual tagging:

<style type="text/css">.gallerycontroller{width: 250px}.gallerycontent{width: 250px;height: 200px;border: 1px solid black;background-color: #000077;padding: 3px;display: block;}</style><script type="text/javascript">var tickspeed=3000 //ticker speed in miliseconds (2000=2 seconds)var displaymode="auto"if (document.getElementById){document.write('<style type="text/css">\n')document.write('.gallerycontent{display:none;}\n')document.write('</style>\n')}var selectedDiv=0var totalDivs=0function getElementbyClass(classname){partscollect=new Array()var inc=0var alltags=document.all? document.all.tags("DIV") : document.getElementsByTagName("*")for (i=0; i<alltags.length; i++){if (alltags[i].className==classname)partscollect[inc++]=alltags[i]}}function contractall(){var inc=0while (partscollect[inc]){partscollect[inc].style.display="none"inc++}}function expandone(){var selectedDivObj=partscollect[selectedDiv]contractall()selectedDivObj.style.display="block"temp.options[selectedDiv].selected=trueselectedDiv=(selectedDiv<totalDivs-1)? selectedDiv+1 : 0if (displaymode=="auto")autocontrolvar=setTimeout("expandone()",tickspeed)}function populatemenu(){temp=document.gallerycontrol.menufor (m=temp.options.length-1;m>0;m--)temp.options[m]=nullfor (i=0;i<totalDivs;i++){var thesubject=partscollect[i].getAttribute("subject")thesubject=(thesubject=="" || thesubject==null)? "HTML Content "+(i+1) : thesubjecttemp.options[i]=new Option(thesubject,"")}temp.options[0].selected=true}function manualcontrol(menuobj){if (displaymode=="manual"){selectedDiv=menuobjexpandone()}}function preparemode(themode){displaymode=themodeif (typeof autocontrolvar!="undefined")clearTimeout(autocontrolvar)if (themode=="auto"){document.gallerycontrol.menu.disabled=trueautocontrolvar=setTimeout("expandone()",tickspeed)}elsedocument.gallerycontrol.menu.disabled=false}function startgallery(){document.getElementById("controldiv").style.display="block"getElementbyClass("gallerycontent")totalDivs=partscollect.lengthpopulatemenu()for (i=0; i<document.gallerycontrol.mode.length; i++){if (document.gallerycontrol.mode[i].checked)displaymode=document.gallerycontrol.mode[i].value}if (displaymode=="auto")document.gallerycontrol.menu.disabled=trueexpandone()}if (window.addEventListener)window.addEventListener("load", startgallery, false)else if (window.attachEvent)window.attachEvent("onload", startgallery)else if (document.getElementById)window.onload=startgallery</script>

...<td rowspan="4" valign="top" style="align: center;"><center><table border="0" cellpadding="3" cellspacing="3" align="center" width="650px" style="text-align: center;">	<tr>		<th><h1>ClanWar Table</h1><hr color="white" width="50%"></th>	</tr>	<tr>		<td><div class="gallerycontent" subject=":[DS]:"><b><u>:[DS]:</u></b><br>Wins: 0<br>Loses: 0<br>Ties: 0<br></div><div class="gallerycontent" subject="AW"><b><u>AW</u></b><br>Wins: 2<br>Loses: 1<br>Ties: 0<br></div><div class="gallerycontent" subject="SEAL"><b><u>SEAL</u></b><br>Wins: 0<br>Loses: 2<br>Ties: 0<br></div><div class="gallerycontent" subject="BR"><b><u>BR</u></b><br>Wins: 0<br>Loses: 0<br>Ties: 0<br></div><div class="gallerycontent" subject="DANK"><b><u>DANK</u></b><br>Wins: 1<br>Loses: 0<br>Ties: 0<br></div><div class="gallerycontent" subject="TSS"><b><u>TSS</u></b><br>Wins: 1<br>Loses: 0<br>Ties: 0<br></div><div id="controldiv" style="display:none; align: center;" class="gallerycontroller"><form name="gallerycontrol">		<select class="gallerycontroller" size="3" name="menu" onChange="manualcontrol(this.options.selectedIndex)">		<option>Blank form</option>		</select><br>Auto: <input type="radio" checked name="mode" value="auto" onClick="preparemode('auto')"> Manual: <input type="radio" name="mode" value="manual" onClick="preparemode('manual')"></form></div></td></tr>	</table></center>		</td>

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...