I'm having a hard time getting a div with Javascript on my professor's website to space properly with the rest of the site. I've tried adjusting the margin and a few suggestions on other Stackoverflow.com threads (e.g. CSS: Center block but left align contents), but none of it seemed to work.
Basically I'm trying to get the links to be further up on the page like the other pages.
What I have is:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<link rel="stylesheet" type="text/css" href="ecl.css" />
<title>Sarah Lawrence College: Research</title>
<script type="text/javascript">
function hideshow(which){
if (!document.getElementById)
return
if (which.style.display=="block")
which.style.display="none"
else
which.style.display="block"
}
</script>
</head>
<body>
<div id="header"><img src="images/celab-header-reduced.jpg" /></div>
<div id="navigation">
<ul>
<li><a href="index.html">About</a></li>
<li><a href="research.html">Research</a></li>
<li><a href="teaching.html">Teaching</a></li>
<li><a href="publications.html">Publications</a></li>
<li><a href="members.html">Lab Members</a></li>
<li><a href="contact.html">Contact</a></li>
</ul>
</div>
<div id="researchcontent">
<ul>
<li>
<div class="showhide"><a href="javascript:hideshow(document.getElementById('ptsd'))">
<h1>Posttraumatic Stress Disorder (PTSD)</h1>
</a></div>
<div id="ptsd">We are currently a series of studies using cognitive and brain imaging techniques to examine the impact of combat trauma on memory and emotion. These studies focus on how perceptions of one’s self impact cognitive, behavioral, and biological processes associated with recovery from combat trauma.</div>
</li>
So on so forth... ending with.
</li>
</ul>
</p>
</div>
</body>
</html>
For the CSS I have:
/* Structure */
div#content {
width:600px;
float:center;
margin:auto;
}
div#navigation {
float:left;
margin:auto auto;
}
div#footer {
clear:both;
text-align:center;
font-size:14px;
font-family:Times New Roman, Times, serif;
}
div#researchcontent {
width:600px;
float:center;
margin:auto;
}
/* Research */
div.showhide {
clear:both;
margin:0px;
}
div#ptsd {
display:none;
}
div#memory {
display:none;
}
div#futureself {
display:none;
}
div#socialremembering {
display:none;
}
div#trauma {
display:none;
}