How to get a quicker, more complete answer.
3) The hover can be accomplished using CSS but not the 'click to hide'. CSS is presentation, not behavior.
HTML:
[HTML]
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>blah</title>
<link rel="stylesheet" type="text/css" href="TemplateCSS.css" />
<script type="text/javascript" src="TemplateJS.js"></script>
</head>
<body>
<div id="global">
<div id="sideBar">
<img id="logoPicture" src="planet.bmp" alt="logo" />
<ul id="navigationList">
<li>Nexus</li>
<li>Mining</li>
<li>Processing</li>
<li>Battle Centre</li>
<li>Ship Yard</li>
<li>Scanning</li>
<li>Construction</li>
<li>Research</li>
<li>Power Control</li>
</ul>
<hr />
<ul id="communityOptions">
<li>Politics</li>
<li>Mail</li>
<li>Planet Defenses</li>
</ul>
<hr />
<ul id="accountOptions">
<li>Log out</li>
<li>Settings</li>
</ul>
<hr />
</div>
<div id="mainContent">
<div id="playerInfo">
<p id="welcomeMess">Welcome to 'region_name' imperator 'character_name'</p>
<p id="serverTime">Server Time:21:23:12</p>
<table id="resourcesTable">
<tbody>
<tr>
<td class="pictureCell"><img class="resTabPic" src="Random.bmp" alt="piccy" /></td>
<td class="nameCell">mehblahbla</td>
<td class="dataCell">99999 m<sup>3</sup></td>
<td class="tableSpacer"></td>
<td class="pictureCell"><img class="resTabPic" src="Random.bmp" alt="piccy" /></td>
<td class="nameCell">mehblahbla</td>
<td class="dataCell">99999 m<sup>3</sup></td>
</tr>
<tr>
<td class="pictureCell"><img class="resTabPic" src="Random.bmp" alt="piccy" /></td>
<td class="nameCell">mehblahbla</td>
<td class="dataCell">99999 m<sup>3</sup></td>
<td class="tableSpacer"></td>
<td class="pictureCell"><img class="resTabPic" src="Random.bmp" alt="piccy" /></td>
<td class="nameCell">mehblahbla</td>
<td class="dataCell">99999 m<sup>3</sup></td>
</tr>
<tr>
<td class="pictureCell"><img class="resTabPic" src="Random.bmp" alt="piccy" /></td>
<td class="nameCell">mehblahbla</td>
<td class="dataCell">99999 m<sup>3</sup></td>
<td class="tableSpacer"></td>
<td class="pictureCell"><img class="resTabPic" src="Random.bmp" alt="piccy" /></td>
<td class="nameCell">mehblahbla</td>
<td class="dataCell">99999 m<sup>3</sup></td>
</tr>
<tr>
<td class="pictureCell"><img class="resTabPic" src="Random.bmp" alt="piccy" /></td>
<td class="nameCell">Population</td>
<td class="dataCell">40/60 Million</td>
<td class="tableSpacer"></td>
<td class="pictureCell"><img class="resTabPic" src="Random.bmp" alt="piccy" /></td>
<td class="nameCell">Power Usage</td>
<td class="dataCell">13/30 GigaWatts</td>
</tr>
</tbody>
</table>
<div id="infoVisibility" onclick="visInfo()">▲ ▲ ▲ ▲ ▲ ▲ ▲ ▲ ▲ ▲ ▲ ▲ ▲ ▲ ▲</div>
</div>
<!-- ********Page Content*********** -->
<div id="pageTitleDiv">
Research
</div>
<div class="researchOption">
Nexus
<img class="researchTabPic" src="" alt="piccy" />
<p class="researchTabInfo">Researched: 2 <br /> Available: 6</p>
</div>
<div class="researchOption">
Mining
<img class="researchTabPic" src="" alt="piccy" />
<p class="researchTabInfo">Researched: 2 <br /> Available: 6</p>
</div>
<div class="researchOption">
Processing
<img class="researchTabPic" src="" alt="piccy" />
<p class="researchTabInfo">Researched: 2 <br /> Available: 6</p>
</div>
<div class="researchOption">
Battle Centre
<img class="researchTabPic" src="" alt="piccy" />
<p class="researchTabInfo">Researched: 2 <br /> Available: 6</p>
</div>
<div class="researchOption">
Ship Yard
<img class="researchTabPic" src="" alt="piccy" />
<p class="researchTabInfo">Researched: 2 <br /> Available: 6</p>
</div>
<div class="researchOption">
Scanning
<img class="researchTabPic" src="" alt="piccy" />
<p class="researchTabInfo">Researched: 2 <br /> Available: 6</p>
</div>
<div class="researchOption">
Construction
<img class="researchTabPic" src="" alt="piccy" />
<p class="researchTabInfo">Researched: 2 <br /> Available: 6</p>
</div>
<div class="researchOption">
Research
<img class="researchTabPic" src="" alt="piccy" />
<p class="researchTabInfo">Researched: 2 <br /> Available: 6</p>
</div>
<div class="researchOption">
Power Control
<img class="researchTabPic" src="" alt="piccy" />
<p class="researchTabInfo">Researched: 2 <br /> Available: 6</p>
</div>
<!-- ******End Page Content******** -->
</div>
</div>
</body>
</html>
[/HTML]
CSS:
Javascript
-
window.onload = windowLoad;
-
-
function windowLoad()
-
{
-
-
hoverController();
-
siteProtection();
-
-
}
-
-
-
function hoverController()
-
{
-
var sideBar = document.getElementById('sideBar');
-
var listElements = sideBar.getElementsByTagName('li');
-
var max = listElements.length;
-
for(var i=0; i<max; i++)
-
{
-
listElements[i].onmouseover=function()
-
{
-
this.style.backgroundColor= "#E8F4FF";
-
this.style.borderColor= "#404080";
-
this.style.color= "#404080";
-
this.style.cursor= "pointer";
-
}
-
listElements[i].onmouseout=function()
-
{
-
this.style.backgroundColor= "#E6EDF5";
-
this.style.borderColor= "#D4E0EE";
-
this.style.color= "#4F76A3";
-
}
-
}
-
-
-
var infoHiderDiv = document.getElementById('infoVisibility');
-
infoHiderDiv.onmouseover=function()
-
{
-
this.style.backgroundColor= "#E8F4FF";
-
this.style.color= "#404080";
-
this.style.cursor= "pointer";
-
}
-
infoHiderDiv.onmouseout=function()
-
{
-
this.style.backgroundColor= "#E6EDF5";
-
this.style.color= "#4F76A3";
-
}
-
}
-
-
-
function siteProtection()
-
{
-
var htmlBody = document.getElementsByTagName('body');
-
htmlBody[0].ondragstart= function(){return false};
-
htmlBody[0].onselectstart= function(){return false};
-
}
-
-
-
function visInfo()
-
{
-
var playerInfo = document.getElementById('playerInfo');
-
var divButton = document.getElementById('infoVisibility');
-
if(playerInfo.style.height == "16px")
-
{
-
playerInfo.style.height = "150px";
-
divButton.innerHTML = "▲ ▲ ▲ ▲ ▲ ▲ ▲ ▲ ▲ ▲ ▲ ▲ ▲ ▲ ▲";
-
}
-
else
-
{
-
playerInfo.style.height = "16px";
-
divButton.innerHTML = "▼ ▼ ▼ ▼ ▼ ▼ ▼ ▼ ▼ ▼ ▼ ▼ ▼ ▼ ▼";
-
}
-
}
-