|
Junior Member
Join Date: 05-05-08
Posts: 3
Latest Blog: None
|
For my current navigation I used dreamweaver to begin. I wouldn't mind trashing the whole thing though.
Sorry about that, here is a simplified version:
CSS
<style type="text/css">
<!--
body {
font: 100% Verdana, Arial, Helvetica, sans-serif; background-image:url(images/BGstripe.png); background-repeat:repeat;
text-align: center; /* this centers the container in IE 5* browsers. The text is then set to the left aligned default in the #container selector */
color: #000000;
}
.oneColFixCtrHdr #container {
width: 928px; /* using 20px less than a full 800px width allows for browser chrome and avoids a horizontal scroll bar */
height: 598px;
margin:52px auto;
border: 0px ;
text-align: left; /* this overrides the text-align: center on the body element. */
}
.oneColFixCtrHdr #header {
background-image: url(images/Header.png);
width: 928px;
height:78px;
/* this padding matches the left alignment of the elements in the divs that appear beneath it. If an image is used in the #header instead of text, you may want to remove the padding. */
}
.oneColFixCtrHdr #header h1 {
margin: ; /* zeroing the margin of the last element in the #header div will avoid margin collapse - an unexplainable space between divs. If the div has a border around it, this is not necessary as that also avoids the margin collapse */
padding:; /* using padding instead of margin will allow you to keep the element away from the edges of the div */
}
.oneColFixCtrHdr #mainContent {
width: 928px; background-color:#faedd3;
background-image: url(images/MiddleImage.jpg);
/* remember that padding is the space inside the div box and margin is the space outside the div box */
}
.oneColFixCtrHdr #footer {
background-image:url(images/Footer-main.png); /* this padding matches the left alignment of the elements in the divs that appear above it. */
width: 928px;
height:28px;
}
.oneColFixCtrHdr #footer p {
/* zeroing the margins of the first element in the footer will avoid the possibility of margin collapse - a space between divs */
padding: ; /* padding on this element will create space, just as the the margin would have, without the margin collapse issue */
}
-->
</style>
JAVASCRIPT(I used dreamweaver)
<script type="text/javascript">
<!--
function MM_swapImgRestore() { //v3.0
var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}
function MM_preloadImages() { //v3.0
var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}
function MM_findObj(n, d) { //v4.01
var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
if(!x && d.getElementById) x=d.getElementById(n); return x;
}
function MM_swapImage() { //v3.0
var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
function MM_nbGroup(event, grpName) { //v6.0
var i,img,nbArr,args=MM_nbGroup.arguments;
if (event == "init" && args.length > 2) {
if ((img = MM_findObj(args[2])) != null && !img.MM_init) {
img.MM_init = true; img.MM_up = args[3]; img.MM_dn = img.src;
if ((nbArr = document[grpName]) == null) nbArr = document[grpName] = new Array();
nbArr[nbArr.length] = img;
for (i=4; i < args.length-1; i+=2) if ((img = MM_findObj(args[i])) != null) {
if (!img.MM_up) img.MM_up = img.src;
img.src = img.MM_dn = args[i+1];
nbArr[nbArr.length] = img;
} }
} else if (event == "over") {
document.MM_nbOver = nbArr = new Array();
for (i=1; i < args.length-1; i+=3) if ((img = MM_findObj(args[i])) != null) {
if (!img.MM_up) img.MM_up = img.src;
img.src = (img.MM_dn && args[i+2]) ? args[i+2] : ((args[i+1])? args[i+1] : img.MM_up);
nbArr[nbArr.length] = img;
}
} else if (event == "out" ) {
for (i=0; i < document.MM_nbOver.length; i++) {
img = document.MM_nbOver[i]; img.src = (img.MM_dn) ? img.MM_dn : img.MM_up; }
} else if (event == "down") {
nbArr = document[grpName];
if (nbArr)
for (i=0; i < nbArr.length; i++) { img=nbArr[i]; img.src = img.MM_up; img.MM_dn = 0; }
document[grpName] = nbArr = new Array();
for (i=2; i < args.length-1; i+=2) if ((img = MM_findObj(args[i])) != null) {
if (!img.MM_up) img.MM_up = img.src;
img.src = img.MM_dn = (args[i+1])? args[i+1] : img.MM_up;
nbArr[nbArr.length] = img;
} }
}
//-->
</script>
HTML
<!-- Begin Navigation -->
<div align="right" style="width:65; height:28;">
<a href="javascript:;" target="_top" onclick="MM_nbGroup('down','group1','OurMenus','im ages/Nav_OurMenus-Down.png',1)" onmouseover="MM_nbGroup('over','OurMenus','images/Nav_OurMenus-Down.png','images/Nav_OurMenus-Down.png',1)" onmouseout="MM_nbGroup('out')"><img src="images/Nav_OurMenus-Up.png" alt="Our Menus" name="OurMenus" width="129" height="28" border="0" id="OurMenus" onload="" /></a>
<a href="/HoursAndDirections" target="_top" onclick="MM_nbGroup('down','group1','HoursDirectio ns','images/Nav_HoursDirections-Down.png',1)" onmouseover="MM_nbGroup('over','HoursDirections',' images/Nav_HoursDirections-Down.png','images/Nav_HoursDirections-Down.png',1)" onmouseout="MM_nbGroup('out')"><img src="images/Nav_HoursDirections-Up.png" alt="Hours Directions" name="HoursDirections" width="159" height="28" border="0" id="HoursDirections" onload="" /></a>
<a href="/PrivateEvents" target="_top" onclick="MM_nbGroup('down','group1','PrivateEvents ','images/Nav_PrivateEvents-Down.png',1)" onmouseover="MM_nbGroup('over','PrivateEvents','im ages/Nav_PrivateEvents-Down.png','images/Nav_PrivateEvents-Down.png',1)" onmouseout="MM_nbGroup('out')"><img src="images/Nav_PrivateEvents-Up.png" alt="Private Events" name="PrivateEvents" width="131" height="28" border="0" id="PrivateEvents" onload="" /></a>
<a href="/Press" target="_top" onclick="MM_nbGroup('down','group1','Press','image s/Nav_Press-Down.png',1)" onmouseover="MM_nbGroup('over','Press','images/Nav_Press-Down.png','images/Nav_Press-Down.png',1)" onmouseout="MM_nbGroup('out')"><img src="images/Nav_Press-Up.png" alt="Press" name="Press" width="66" height="28" border="0" id="Press" onload="" /></a>
<a href="javascript:;" target="_top" onclick="MM_nbGroup('down','group1','More','images/Nav_More-Down.png',1)" onmouseover="MM_nbGroup('over','More','images/Nav_More-Down.png','images/Nav_More-Down.png',1)" onmouseout="MM_nbGroup('out')"><img src="images/Nav_More-Up.png" alt="More" name="More" width="65" height="28" border="0" id="More" onload="" /></a> </div>
<!-- End Navigation -->
|