Menu
I am looking for a clean (not bulky) looking drop down menu. I know HTML but am not very good with JavaScript so I will need something simple. Can someone recommend a good looking drop down menu that I can use easily? Any help would be greatly appreciated. Thanks
[CODE]//Chrome Drop Down Menu- Author: Dynamic Drive (http://www.dynamicdrive.com)
//Last updated: June 14th, 06'
var cssdropdown={
disappeardelay: 250, //set delay in miliseconds before menu disappears onmouseout
disablemenuclick: false, //when user clicks on a menu item with a drop down menu, disable menu item's link?
enableswipe: 1, //enable swipe effect? 1 for yes, 0 for no
//No need to edit beyond here////////////////////////
dropmenuobj: null, ie: document.all, firefox: document.getElementById&&!document.all, swipetimer: undefined, bottomclip:0,
getposOffset:function(what, offsettype){
var totaloffset=(offsettype=="left")? what.offsetLeft : what.offsetTop;
var parentEl=what.offsetParent;
while (parentEl!=null){
totaloffset=(offsettype=="left")? totaloffset+parentEl.offsetLeft : totaloffset+parentEl.offsetTop;
parentEl=parentEl.offsetParent;
}
return totaloffset;
},
swipeeffect:function(){
if (this.bottomclip<parseInt(this.dropmenuobj.offsetHeight)){
this.bottomclip+=10+(this.bottomclip/10) //unclip drop down menu visibility gradually
this.dropmenuobj.style.clip="rect(0 auto "+this.bottomclip+"px 0)"
}
else
return
this.swipetimer=setTimeout("cssdropdown.swipeeffect()", 10)
},
showhide:function(obj, e){
if (this.ie || this.firefox)
this.dropmenuobj.style.left=this.dropmenuobj.style.top="-500px"
if (e.type=="click" && obj.visibility==hidden || e.type=="mouseover"){
if (this.enableswipe==1){
if (typeof this.swipetimer!="undefined")
clearTimeout(this.swipetimer)
obj.clip="rect(0 auto 0 0)" //hide menu via clipping
this.bottomclip=0
this.swipeeffect()
}
obj.visibility="visible"
}
else if (e.type=="click")
obj.visibility="hidden"
},
iecompattest:function(){
return (document.compatMode && document.compatMode!="BackCompat")? document.documentElement : document.body
},
clearbrowseredge:function(obj, whichedge){
var edgeoffset=0
if (whichedge=="rightedge"){
var windowedge=this.ie && !window.opera? this.iecompattest().scrollLeft+this.iecompattest().clientWidth-15 : window.pageXOffset+window.innerWidth-15
this.dropmenuobj.contentmeasure=this.dropmenuobj.offsetWidth
if (windowedge-this.dropmenuobj.x < this.dropmenuobj.contentmeasure) //move menu to the left?
edgeoffset=this.dropmenuobj.contentmeasure-obj.offsetWidth
}
else{
var topedge=this.ie && !window.opera? this.iecompattest().scrollTop : window.pageYOffset
var windowedge=this.ie && !window.opera? this.iecompattest().scrollTop+this.iecompattest().clientHeight-15 : window.pageYOffset+window.innerHeight-18
this.dropmenuobj.contentmeasure=this.dropmenuobj.offsetHeight
edgeoffset=this.dropmenuobj.contentmeasure+obj.offsetHeight
if ((this.dropmenuobj.y-topedge)<this.dropmenuobj.contentmeasure) //up no good either?
edgeoffset=this.dropmenuobj.y+obj.offsetHeight-topedge
}
return edgeoffset
},
dropit:function(obj, e, dropmenuID){
if (this.dropmenuobj!=null) //hide previous menu
this.dropmenuobj.style.visibility="hidden" //hide menu
this.clearhidemenu()
if (this.ie||this.firefox){
obj.onmouseout=function(){cssdropdown.delayhidemenu()}
obj.onclick=function(){return !cssdropdown.disablemenuclick} //disable main menu item link onclick?
this.dropmenuobj=document.getElementById(dropmenuID)
this.dropmenuobj.onmouseover=function(){cssdropdown.clearhidemenu()}
this.dropmenuobj.onmouseout=function(){cssdropdown.dynamichide(e)}
this.dropmenuobj.onclick=function(){cssdropdown.delayhidemenu()}
this.showhide(this.dropmenuobj.style, e)
this.dropmenuobj.x=this.getposOffset(obj, "left")
this.dropmenuobj.y=this.getposOffset(obj, "top")
this.dropmenuobj.style.left=this.dropmenuobj.x-this.clearbrowseredge(obj, "rightedge")+"px"
this.dropmenuobj.style.top=this.dropmenuobj.y-this.clearbrowseredge(obj, "bottomedge")+obj.offsetHeight+1+"px"
}
},
contains_firefox:function(a, b) {
while (b.parentNode)
if ((b = b.parentNode) == a)
return true;
return false;
},
dynamichide:function(e){
var evtobj=window.event? window.event : e
if (this.ie&&!this.dropmenuobj.contains(evtobj.toElement))
this.delayhidemenu()
else if (this.firefox&&e.currentTarget!= evtobj.relatedTarget&& !this.contains_firefox(evtobj.currentTarget, evtobj.relatedTarget))
this.delayhidemenu()
},
delayhidemenu:function(){
this.delayhide=setTimeout("cssdropdown.dropmenuobj.style.visibility='hidden'",this.disappeardelay) //hide menu
},
clearhidemenu:function(){
if (this.delayhide!="undefined")
clearTimeout(this.delayhide)
},
startchrome:function(){
for (var ids=0; ids<arguments.length; ids++){
var menuitems=document.getElementById(arguments[ids]).getElementsByTagName("a")
for (var i=0; i<menuitems.length; i++){
if (menuitems[i].getAttribute("rel")){
var relvalue=menuitems[i].getAttribute("rel")
menuitems[i].onmouseover=function(e){
var event=typeof e!="undefined"? e : window.event
cssdropdown.dropit(this,event,this.getAttribute("rel"))
}
}
}
}
}
}[/CODE]
[code=html]a, a:visited
{
color: gray;
text-decoration: none;
}
a:hover
{
color: white;
text-decoration: underline;
}
a.grijs, a.grijs:visited
{
color: #656565;
text-decoration: none;
font-weight: bold;
}
a.grijs:hover
{
color: #656565;
text-decoration: none;
font-weight: bold;
}
a.rood, a.rood:visited
{
color: gray;
text-decoration: none;
font: bold 10px Verdana;
}
a.rood:hover
{
color: white;
text-decoration: none;
font: bold 10px Verdana;
}
chromestyle:after{ /*Add margin between menu and rest of content in Firefox*/
content: ".";
display: block;
height: 0;
clear: both;
visibility: hidden;
}
.chromestyle ul{
padding: 0;
margin: 0;
text-align: center; /*set value to "left", "center", or "right"*/
}
/* ######### Kleur van de strepen ######### */
.chromestyle ul li{
display: inline;
font-weight: bold;
color: #999;
}
.chromestyle ul li a{
margin: 0;
text-decoration: none;
font: 10px Verdana;
font-weight: bold;
color: #gray;
}
/* ######### Text effect menu items ######### */
.chromestyle ul li a:hover{
text-decoration: none;
font-weight: bold;
color: white;
}
.chromestyle ul li a[rel]:after{ /*HTML to indicate drop down link*/
content: "";
/*content: " " url(downimage.gif); /*uncomment this line to use an image instead*/
}
/* ######### Style for Drop Down Menu ######### */
.dropmenudiv{
position:absolute;
top: 0;
border: 1px solid #1b2025; /*THEME CHANGE HERE*/
border-bottom-width: 0;
font:normal 10px Verdana;
line-height:18px;
z-index:100;
background-color: #bebebe;
width: 92px;
visibility: hidden;
}
.dropmenudiv a{
width: auto;
display: block;
text-indent: 3px;
border-bottom: 1px solid #1b2025; /*THEME CHANGE HERE*/
padding: 2px 0;
text-decoration: none;
font-weight: bold;
color: black;
}
.dropmenudiv a:hover{
text-decoration: none;
color: white;
}
* html .dropmenudiv a{ /*IE only hack*/
width: 100%;
}
.dropmenudiv a:hover{ /*THEME CHANGE HERE*/
background-color: #a1a1a1;
}[/code]
[code=html]
<link rel="stylesheet" type="text/css" href="dropdown.css" />
<script type="text/javascript" src="chrome.js">
/***********************************************
* Chrome CSS Drop Down Menu- © Dynamic Drive DHTML code library (www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit Dynamic Drive at http://www.dynamicdrive.com/ for full source code
***********************************************/
</script>[/code]
[code=html]<div id="rand_klein"></div>
<div id="menu">
<div class="chromestyle" id="chromemenu">
<ul>
<li><a href="werkzaamheden.html" target="main">Werkzaamheden</a></li>
<font face="Times New Roman" color="white" size="2"> | </font>
<li><a href="#" rel="dropmenu1">Portfolio</a></li>
<font face="Times New Roman" color="white" size="2"> | </font>
<li><a href="">Menu #3</a></li>
<font face="Times New Roman" color="white" size="2"> | </font>
<li><a href="">Menu #4</a></li>
</ul>
</div>
<div id="dropmenu1" class="dropmenudiv">
<a href="badkamer.html" target="main">Badkamer</a>
<a href="">Submenu #2</a>
<a href="">Submenu #3</a>
<a href="">Submenu #4</a>
</div> <script type="text/javascript">cssdropdown.startchrome("chromemenu")</script>
</div>[/code]
[CODE]#menu ul {
float: none !important;
float: left; /* Must apply a float to the element to get it to work in IE */
opacity: 0.5;
filter: alpha(opacity=50);
-moz-opacity: 0.5;
filter: progid:DXImageTransform.Microsoft.Alpha(opacity=50);
}[/CODE]
[CODE]/* Menu
---------------------------------------------------------------------------------------- */
#menu {
width: 100%;
float: left;
margin: 0;
padding: 0;
list-style: none;
background: #EFF3E2;
border-top: 1px solid #CFD8A9;
border-right: 1px solid #CFD8A9;
border-bottom: 1px solid #CFD8A9;
font-size: 100%;
}
#menu li {
float: left;
margin: 0;
padding: 0;
position: relative;
}
#menu a {
float: left;
display: block;
padding: 7px 16px;
text-decoration: none;
color: #486A00;
font-weight: bold;
border-right: 1px solid #FAFBF7;
border-left: 1px solid #DEE7C2;
}
#menu a:hover {background: #E1E7C9;}
/* The Drop Down: */
#menu .parent a {background: url(../images/bullet_arrow_down.png) no-repeat right center;}
#menu .activeParent a {
color: #333300;
background: #E1E7C9 url(../images/bullet_arrow_down.png) no-repeat right center;
}
#menu .parent ul {display: none;} /* Hides the dropdown */
#menu .activeParent ul {
float: left;
width: 12em; /* The width of the dropdown */
margin: 0;
padding: 0;
position: absolute;
top: 2.3em !important; /* For Standard Compliant Browsers */
top: 2.2em; /* For IE */
left: 0;
list-style: none;
z-index: 1000;
}
[B]#menu ul {
float: none !important;
float: left; /* Must apply a float to the element to get it to work in IE */
opacity: 0.5;
filter: alpha(opacity=50);
-moz-opacity: 0.5;
filter: progid:DXImageTransform.Microsoft.Alpha(opacity=50);
}[/B]
#menu .activeParent li {
float: left;
margin: 0;
padding: 0;
}
#menu .activeParent li a {
float: left;
width: 12em; /* The width of the dropdown */
margin: 0;
padding: 3px 8px;
color: #556A28;
display: block;
background: #FFFFFF;
font-size: 90%;
border-bottom: 1px solid #CFD8A9;
border-right: 1px solid #CFD8A9;
border-left: 1px solid #CFD8A9;
}
#menu .activeParent li a:hover {
background: #E1E7C9;
color: #333300;
}[/CODE]
I recently wrote a dropdown menu using minimal JS and CSS. Check it out, it may work for you.
http://dev.organixdesign.com/drop_down_menu/ [/QUOTE]
[CODE]/* Menu
---------------------------------------------------------------------------------------- */
#menu {
width: 100%;
float: left;
margin: 0;
padding: 0;
list-style: none;
background: #EFF3E2;
border-top: 1px solid #CFD8A9;
border-right: 1px solid #CFD8A9;
border-bottom: 1px solid #CFD8A9;
font-size: 100%;
}
#menu li {
float: left;
margin: 0;
padding: 0;
position: relative;
}
#menu a {
float: left;
display: block;
padding: 7px 16px;
text-decoration: none;
color: #486A00;
font-weight: bold;
border-right: 1px solid #FAFBF7;
border-left: 1px solid #DEE7C2;
}
#menu a:hover {background: #E1E7C9;}
/* The Drop Down: */
#menu .parent a {background: url(../images/bullet_arrow_down.png) no-repeat right center;}
#menu .activeParent a {
color: #333300;
background: #E1E7C9 url(../images/bullet_arrow_down.png) no-repeat right center;
}
#menu .parent ul {display: none;} /* Hides the dropdown */
#menu .activeParent ul {
float: left;
width: 12em; /* The width of the dropdown */
margin: 0;
padding: 0;
position: absolute;
top: 2.3em !important; /* For Standard Compliant Browsers */
top: 2.2em; /* For IE */
left: 0;
list-style: none;
z-index: 1000;
}
#menu .activeParent li {
float: left;
margin: 0;
padding: 0;
}
#menu .activeParent li a {
float: left;
width: 12em; /* The width of the dropdown */
margin: 0;
padding: 3px 8px;
color: #556A28;
display: block;
background: #FFFFFF;
font-size: 90%;
border-bottom: 1px solid #CFD8A9;
border-right: 1px solid #CFD8A9;
border-left: 1px solid #CFD8A9;
}
#menu .activeParent li a:hover {
background: #E1E7C9;
color: #333300;
}[/CODE]
[CODE]// GetElementsByClass Function
function getElementsByClass(className) {
var all = document.all ? document.all : document.getElementsByTagName('*');
var elements = new Array();
for (var i = 0; i < all.length; i++)
if (all[i].className == className)
elements[elements.length] = all[i];
return elements;
}
// Menu Function
function menu(start,hover) {
var elm = getElementsByClass(start);
for (i=0; i < elm.length; i++) {
elm[i].onmouseover = function() {
this.className = hover;
this.onmouseout = function() {
this.className = start;
}
}
}
}
// Call Menu Function on page load
window.onload = function() {
menu('parent','activeParent');
}[/CODE]
[code=html]
<ul id="menu">
<li><a href="#" title="Title Here">Home</a></li>
<li><a href="#" title="Title Here">About</a></li>
<li class="parent"><a href="#" title="Title Here">Portfolio</a>
<ul>
<li><a href="#" title="Title Here">Sub Item</a></li>
<li><a href="#" title="Title Here">Another Sub Item</a></li>
<li><a href="#" title="Title Here">Sub Item</a></li>
</ul>
</li>
<li class="parent"><a href="#" title="Title Here">Services</a>
<ul>
<li><a href="#" title="Title Here">Sub Item</a></li>
<li><a href="#" title="Title Here">Another Sub Item</a></li>
<li><a href="#" title="Title Here">Sub Item</a></li>
</ul>
</li>
<li class="parent"><a href="#" title="Title Here">Services</a>
<ul>
<li><a href="#" title="Title Here">Sub Item</a></li>
<li><a href="#" title="Title Here">Another Sub Item</a></li>
<li><a href="#" title="Title Here">Sub Item</a></li>
</ul>
</li>
<li><a href="#" title="Title Here">Contact</a></li>
</ul>
[/code]
[code=html]
<link rel="stylesheet" type="text/css" href="css/menu.css" />
<script type="text/javascript" src="js/menu.js"></script>
[/code]
Could you post the html that you have? You probably didnt link to the css/js properly in the <head> of the document. Double check that[/QUOTE]
<li class="parent"><a href="#" title="Title Here">Portfolio</a>
<ul>
<li><a href="#" title="Title Here">Sub Item</a></li>
<li><a href="#" title="Title Here">Another Sub Item</a></li>
<li><a href="#" title="Title Here">Sub Item</a></li>
</ul>
</li>
<li class="parent"><a href="#" title="Title Here">Services</a>
<ul>
<li><a href="#" title="Title Here">Sub Item</a></li>
<li><a href="#" title="Title Here">Another Sub Item</a></li>
<li><a href="#" title="Title Here">Sub Item</a></li>
</ul>
</li>
<li class="parent"><a href="#" title="Title Here">Services</a>
<ul>
<li><a href="#" title="Title Here">Sub Item</a></li>
<li><a href="#" title="Title Here">Another Sub Item</a></li>
<li><a href="#" title="Title Here">Sub Item</a></li>
</ul>
</li>
<li><a href="#" title="Title Here">Contact</a></li>
Hey Susan,
I just updated my demo page with more information and I have the file for download so you can see how it all works and how to link it in:
http://dev.organixdesign.com/demos/drop_down_menu/ [/QUOTE]
Orazzals,
Could you post the code you are working with, or upload a zip of it so I can take a look. Floats are one of the hardest CSS properties to learn to work with, so it can be tricky.[/QUOTE]
[CODE]<div id="menuContainer">
[B]PUT YOUR MENU HERE[/B]
</div>[/CODE]
[CODE]body {font-size: small;}
#menuContainer {
margin: 0 auto;
width: 800px;
}[/CODE]
Thanks Blis that worked. You have been terrific. Thanks so much. Will send you link to site when finished and uploaded.[/QUOTE]
<title>Trucks</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<script type="text/javascript" src="js/menu.js"></script>
<link rel="stylesheet" type="text/css" href="css/menu.css" />
<style type="text/css">
<tr>
<td colspan="3" class="style11"><div align="center" class="style13">
<h2 align="left"> </h2>
<h2><span class="style9">©2007 Paramus Rescue. Web site designed by Susan Lazzaro</span></h2>
</div></td>
</tr>
if(list.selectedIndex == 0)
{
list.selectedIndex = list.options.length-1;
}
else
{
list.selectedIndex--;
}
changeImage();
if(list.selectedIndex == list.options.length-1)
{
list.selectedIndex = 0;
}
else
{
list.selectedIndex++;
}
changeImage();
<select id="list" onchange="javascript:changeImage()">
<option value="image1.jpg">First Image</option>
<option value="image2.jpg">Second Image</option>
<option value="image3.jpg">Third Image</option>
<option value="image4.jpg">Fourth Image</option>
</select>
send me what you got in a zip and ill check it out[/QUOTE]
send me what you got in a zip and ill check it out[/QUOTE]
Susy,
There is no way we can help you if you do not post the Javascript and CSS for your file. Please upload a zip file of your HTML, CSS and Javascript for us to look at.
Th[/QUOTE]
Susy,
There is no way we can help you if you do not post the Javascript and CSS for your file. Please upload a zip file of your HTML, CSS and Javascript for us to look at.
Thanks[/QUOTE]
No, not yet, I was really busy this weekend finishing up a project. Ive got the files on my desktop ready to look at, Ill try and work on it today.
Same goes for you orazzals.[/QUOTE]
Susy,
I had a chance to look at your files and Im trying to find out what the problem you are having is, could you tell me what is going wrong?
(btw, the menu is not located within a TD, but is located int the table, which is invalid. The menu should be put into a TD if you are going to use it within a table.)
Thanks[/QUOTE]
Susy,
I had a chance to look at your files and Im trying to find out what the problem you are having is, could you tell me what is going wrong?
(btw, the menu is not located within a TD, but is located int the table, which is invalid. The menu should be put into a TD if you are going to use it within a table.)
Thanks[/QUOTE]
[code=html]<!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=iso-8859-1" />
<title>Pagetemplate</title>
<style type="text/css">
<!--
body {
background-color: #FFFFCC;
margin-left: 0px;
margin-top: 0px;
margin-right: 0px;
margin-bottom: 0px;
}
-->
</style>
<script language="JavaScript" type="text/javascript" src="../menu.js"></script>
<link href="../menu.css" rel="stylesheet" type="text/css" />
</head>
<body>
<table width="995" border="1">
<tr>
<td width="140" height="130" rowspan="3" bgcolor="#003366"><object classid="clsid27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="140" height="130" title="logo">
<param name="movie" value="../flash/kcah_logo.swf" />
<param name="quality" value="high" />
<embed src="../flash/kcah_logo.swf" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="140" height="130"></embed>
</object></td>
<td width="850" height="30" bgcolor="#003366"> </td>
</tr>
<tr>
<td height="70" align="center" valign="middle" bgcolor="#003366">
<object classid="clsid27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="840" height="70" title="baner">
<param name="movie" value="../flash/kcah_baner.swf" />
<param name="quality" value="high" />
<embed src="../flash/kcah_baner.swf" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="840" height="70"></embed>
</object>
</td>
</tr>
<tr>
<td bgcolor="#003366"><div id="menuContainer">
<ul id="menu">
<li><a href="#" title="Title Here">Home</a></li>
<li><a href="#" title="Title Here">About</a></li>
<li class="parent"><a href="#" title="Title Here">Portfolio</a>
<ul>
<li><a href="#" title="Title Here">Sub Item</a></li>
<li><a href="#" title="Title Here">Another Sub Item</a></li><li><a href="#" title="Title Here">Sub Item</a></li>
</ul>
</li>
<li class="parent"><a href="#" title="Title Here">Services</a>
<ul>
<li><a href="#" title="Title Here">Sub Item</a></li>
<li><a href="#" title="Title Here">Another Sub Item</a></li>
<li><a href="#" title="Title Here">Sub Item</a></li>
</ul>
</li>
<li class="parent"><a href="#" title="Title Here">Services</a>
<ul>
<li><a href="#" title="Title Here">Sub Item</a></li>
<li><a href="#" title="Title Here">Another Sub Item</a></li>
<li><a href="#" title="Title Here">Sub Item</a></li>
</ul>
</li>
<li><a href="#" title="Title Here">Contact</a></li>
</ul>
</div>
</td>
</tr>
</table>
<table width="995" border="1">
<tr>
<td> </td>
</tr>
</table>
<table width="995" border="1">
<tr>
<td width="995" height="20" align="center"></td>
</tr>
</table>
</body>
</html>[/code]
[code=html] <tr>
<td colspan="4">
<!-- Menu : Begin -->
<div id="menuContainer">
<ul id="menu">
<li class="parent"><a href="#" title="Title Here">About Us</a>
<ul>
<li><a href="#" title="Title Here">History</a></li>
<li><a href="#" title="Title Here">Trucks</a></li>
<li><a href="#" title="Title Here">Other Equipment</a></li>
<li><a href="#" title="Title Here">Members</a></li>
</ul>
<li class="parent"><a href="#" title="Title Here">Training</a>
<ul>
<li><a href="#" title="Title Here">Required Classes</a></li>
<li><a href="#" title="Title Here">Class Schedules</a></li>
</ul>
<li class="parent"><a href="#" title="Title Here">On the Scene</a>
<ul>
<li><a href="#" title="Title Here">Before 2005</a></li>
<li><a href="#" title="Title Here">2005</a></li>
<li><a href="#" title="Title Here">2006</a></li>
<li><a href="#" title="Title Here">2007</a></li>
</ul>
</li>
<li class="parent"><a href="#" title="Title Here">Special Events</a>
<ul>
<li><a href="#" title="Title Here">Fundraisers</a></li>
<li><a href="#" title="Title Here">Community Events</a></li>
<li><a href="#" title="Title Here">Competitions</a></li>
</ul>
</li>
<li class="parent"><a href="#" title="Title Here">Information</a>
<ul>
<li><a href="#" title="Title Here">In the News</a></li>
<li><a href="#" title="Title Here">Statistics</a></li>
</ul>
</li>
<li><a href="#" title="Title Here">Join Us</a></li>
<li><a href="#" title="Title Here">Contact Us</a></li>
</ul>
</div>
<!-- Menu : End -->
</td>
</tr>
<tr>
<td colspan="4" class="style10"><h2 align="left"><strong><FONT SIZE="+1">O U R H I S T O R Y</FONT> <br>
</strong></h2>
</td>
</tr>[/code]
[code=html]<!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>
<title>Put Your Page Title Here</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<script type="text/javascript" src="js/menu.js"></script>
<link rel="stylesheet" type="text/css" href="css/menu.css" />
<style type="text/css">
body {
font: small Arial, Helvetica, sans-serif;
margin: 0;
text-align: center;
}
h1 {
font-size: 160%;
letter-spacing: .4em;
}
#container {
margin: 20px auto;
width: 800px;
text-align: left;
}
#footer {
font-size: 90%;
color: #666666;
text-align: center;
}
</style>
</head>
<body>
<!-- Container : Begin -->
<div id="container">
<!-- Menu : Begin -->
<div id="menuContainer">
<ul id="menu">
<li class="parent"><a href="#" title="Title Here">About Us</a>
<ul>
<li><a href="#" title="Title Here">History</a></li>
<li><a href="#" title="Title Here">Trucks</a></li>
<li><a href="#" title="Title Here">Other Equipment</a></li>
<li><a href="#" title="Title Here">Members</a></li>
</ul>
<li class="parent"><a href="#" title="Title Here">Training</a>
<ul>
<li><a href="#" title="Title Here">Required Classes</a></li>
<li><a href="#" title="Title Here">Class Schedules</a></li>
</ul>
<li class="parent"><a href="#" title="Title Here">On the Scene</a>
<ul>
<li><a href="#" title="Title Here">Before 2005</a></li>
<li><a href="#" title="Title Here">2005</a></li>
<li><a href="#" title="Title Here">2006</a></li>
<li><a href="#" title="Title Here">2007</a></li>
</ul>
</li>
<li class="parent"><a href="#" title="Title Here">Special Events</a>
<ul>
<li><a href="#" title="Title Here">Fundraisers</a></li>
<li><a href="#" title="Title Here">Community Events</a></li>
<li><a href="#" title="Title Here">Competitions</a></li>
</ul>
</li>
<li class="parent"><a href="#" title="Title Here">Information</a>
<ul>
<li><a href="#" title="Title Here">In the News</a></li>
<li><a href="#" title="Title Here">Statistics</a></li>
</ul>
</li>
<li><a href="#" title="Title Here">Join Us</a></li>
<li><a href="#" title="Title Here">Contact Us</a></li>
</ul>
</div>
<!-- Menu : End -->
<!-- Content : Begin -->
<div id="content">
<h1>OUR HISTORY</h1>
<p>The Paramus Rescue Squad was established in 1952 under the Civil Defense – Disaster Control Act as directed by Congress. The mission of the Rescue Squad was to prepare for rescues and survival following an atomic attack or war. It was also decided the Squad could respond as a first line unit. Under the direction of Warren G. Hildenbrand (Director), Edward Sharkey (Deputy Director), and Archie A. Petronzio (Operations Officer), the Squad was formed. In 1956 eight men were trained as specialists in heavy duty rescue work.</p>
<!-- CUT AND PASTE THE REST OF YOUR CONTENT INTO <p> TAGS LIKE ABOVE -->
</div>
<!-- Content : End -->
<!-- Footer : Begin -->
<div id="footer">
©2007 Paramus Rescue. Web site designed by Susan Lazzaro
</div>
<!-- Footer : End -->
</div>
<!-- Container : End -->
</body>
</html>[/code]
Its not working because your css file is not linked to correctly in the <head> of the document. Double check the location of your files and try again (I am 100% it works).
Im glad I could help you out and I completely understand your situation. Its a pain in the ass to keep up with Web technology and the only way I can do it is because its my full time job ?
Hope it all works for you,
Cheers[/QUOTE]
Its not working because your css file is not linked to correctly in the <head> of the document. Double check the location of your files and try again (I am 100% it works).
Im glad I could help you out and I completely understand your situation. Its a pain in the ass to keep up with Web technology and the only way I can do it is because its my full time job ?
Hope it all works for you,
Cheers[/QUOTE]
[CODE]#container {
width: 800px;
position: relative;
}
#menu{
float: left;
width: 600px;
position: absolute;
left: 100px;
}[/CODE]
Susy, Try this out:
[code=html]<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
[/QUOTE]
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Pagetemplate</title>
<style type="text/css">
<!--
body {
background-color: #FFFFCC;
margin-left: 0px;
margin-top: 0px;
margin-right: 0px;
margin-bottom: 0px;
}
-->
</style>
<script language="JavaScript" type="text/javascript" src="../menu.js"></script>
<link href="../menu.css" rel="stylesheet" type="text/css" />
</head>
<body>
<table width="995" border="1">
<tr>
<td width="140" height="130" rowspan="3" bgcolor="#003366"><object classid="clsid27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="140" height="130" title="logo">
<param name="movie" value="../flash/kcah_logo.swf" />
<param name="quality" value="high" />
<embed src="../flash/kcah_logo.swf" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="140" height="130"></embed>
</object></td>
<td width="850" height="30" bgcolor="#003366"> </td>
</tr>
<tr>
<td height="70" align="center" valign="middle" bgcolor="#003366">
<object classid="clsid27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="840" height="70" title="baner">
<param name="movie" value="../flash/kcah_baner.swf" />
<param name="quality" value="high" />
<embed src="../flash/kcah_baner.swf" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="840" height="70"></embed>
</object>
</td>
</tr>
<tr>
<td bgcolor="#003366"><div id="menuContainer">
<ul id="menu">
<li><a href="#" title="Title Here">Home</a></li>
<li><a href="#" title="Title Here">About</a></li>
<li class="parent"><a href="#" title="Title Here">Portfolio</a>
<ul>
<li><a href="#" title="Title Here">Sub Item</a></li>
<li><a href="#" title="Title Here">Another Sub Item</a></li><li><a href="#" title="Title Here">Sub Item</a></li>
</ul>
</li>
<li class="parent"><a href="#" title="Title Here">Services</a>
<ul>
<li><a href="#" title="Title Here">Sub Item</a></li>
<li><a href="#" title="Title Here">Another Sub Item</a></li>
<li><a href="#" title="Title Here">Sub Item</a></li>
</ul>
</li>
<li class="parent"><a href="#" title="Title Here">Services</a>
<ul>
<li><a href="#" title="Title Here">Sub Item</a></li>
<li><a href="#" title="Title Here">Another Sub Item</a></li>
<li><a href="#" title="Title Here">Sub Item</a></li>
</ul>
</li>
<li><a href="#" title="Title Here">Contact</a></li>
</ul>
</div>
</td>
</tr>
</table>
<table width="995" border="1">
<tr>
<td> </td>
</tr>
</table>
<table width="995" border="1">
<tr>
<td width="995" height="20" align="center"></td>
</tr>
</table>
</body>
</html>[/code]
[CODE]/* Menu
------------------------------------------------------------------*/
/* Styling the main menu */
#menu {
float: left;
width: 100%;
margin: 0;
padding: 0;
list-style: none;
}
#menu li {
float: left;
position: relative;
margin: 0;
padding: 0;
min-width: 6.1em; /* For Opera */
}
#menu li a {
float: left;
display: block;
/* fixes opera bug: width: 5em; */
margin: 0;
padding: 5px 12px;
font-weight: bold;
color: #666;
text-decoration: none;
}
#menu li a:hover {
background: #fc0;
color: #fff;
}
/* Make menu appear on roll over */
#menu li ul {display: none;}
#menu li:hover ul {display: block;}
/* Styling the drop down */
#menu ul {
float: left;
width: 150px;
position: absolute;
top: 1.9em;
left: 0;
list-style: none;
margin: 0;
padding: 0;
}
#menu ul li {
float: left;
margin: 0;
padding: 0;
}
#menu ul a {
float: left;
width: 150px;
display: block;
background: #fc0;
color: #fff;
margin: 0;
padding: 5px 12px;
}
#menu ul a:hover {
background: #f60;
}[/CODE]
[code=html]<ul id="menu">
<li><a href="#" title="Put Title Here">Home</a></li>
<li><a href="#" title="Put Title Here">About</a></li>
<li><a href="#" title="Put Title Here">Products</a>
<ul>
<li><a href="#" title="Put Title Here">Sofa</a></li>
<li><a href="#" title="Put Title Here">Large Wood Bed Frame</a></li>
<li><a href="#" title="Put Title Here">Rolling Office Chair</a></li>
<li><a href="#" title="Put Title Here">Dresser</a></li>
</ul>
</li>
<li><a href="#" title="Put Title Here">Services</a>
<ul>
<li><a href="#" title="Put Title Here">Custom Work</a></li>
<li><a href="#" title="Put Title Here">Wholesale Orders</a></li>
<li><a href="#" title="Put Title Here">Import/Export</a></li>
</ul>
</li>
<li><a href="#" title="Put Title Here">Contact</a></li>
</ul>[/code]
[CODE]<!--[if IE]>
<style type="text/css" media="screen">
body {behavior: url(js/hover_fix.htc);}
</style>
<![endif]-->[/CODE]
Could you try to be a little more descriptive Susy. What is not working and what does it look like? Double check that the URLs to both the CSS and JS are correct. That is probably the problem[/QUOTE]
Glad I could be of help, good luck on your project. Also, good to hear you are starting to use non-table based layouts, thats a very good idea. Have a good one.
Cheers[/QUOTE]
I do not see why you would need or want to do this, could you explain why you would need such a feature?
You best bet would be to make your layout fluid width (width: 100%) so that no matter the screen size, it will resize accordingly. However there are some inherent problems with this solution (on small screens text can be jammed together, and on big screens it can be spread out a lot). I would say pick a safe width like 700px - 900px or so (most screens these days are 1024px X 768px, so you could go as wide as 1000px if you needed).
Hope that helps[/QUOTE]
I do not see why you would need or want to do this, could you explain why you would need such a feature?
You best bet would be to make your layout fluid width (width: 100%) so that no matter the screen size, it will resize accordingly. However there are some inherent problems with this solution (on small screens text can be jammed together, and on big screens it can be spread out a lot). I would say pick a safe width like 700px - 900px or so (most screens these days are 1024px X 768px, so you could go as wide as 1000px if you needed).
Hope that helps[/QUOTE]
0.1.9 — BETA 6.17