CSS Menu assistance needed - Post ID...

User 133269 Photo


Registered User
2,900 posts

are you trying to set the height on the first menu still?
seems like that'll take a bit o messing round - like almost as much code again on that one....

the chrome one will do images and height on the subs...
this chrome one i messed with the height of subs without too much problem
http://www.summerset.co.nz/
Have fun
~ Fe Pixie ~
User 117361 Photo


Ambassador
6,076 posts

I am only in briefly, but was there not a single menu already including images that you could have adapted? I have a couple of things to do then I will get back to looking at your menu again.
User 38401 Photo


Senior Advisor
10,951 posts

Fe Pixie wrote:
are you trying to set the height on the first menu still?
seems like that'll take a bit o messing round - like almost as much code again on that one....

the chrome one will do images and height on the subs...
this chrome one i messed with the height of subs without too much problem
http://www.summerset.co.nz/


Thanks Pixie, I'll take a look at that one, doesn't look too difficult to manage. I'm a bit confused here though as it looks like it has javascript in it? How does that work with it? I was under the impression that Flash and Java are what I should be trying to get away from for the menu?


Janys Hyde wrote:
I am only in briefly, but was there not a single menu already including images that you could have adapted? I have a couple of things to do then I will get back to looking at your menu again.


I looked again today Janys on that site, and on a couple other sites, but they didn't have a very easy setup for getting the menu so I gave up. Most of them were tabbed menus or just colored ones like the purple one. Wish I had realized there was a difference before lol. I'll play with the one that Pixie posted above and see if I can alter that one accordingly.
User 117361 Photo


Ambassador
6,076 posts

JoAnn
Here you go with the html page code:

<!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" dir="ltr" lang="en-US" xml:lang="en">
<head>

<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>JoAnn</title>

<link rel="stylesheet" href="style.css" type="text/css" media="screen" />

</head>
<body>

<ul class="joann-menu">
<li>
<a href="#" class="active"><span class="l"></span><span class="r"></span><span class="t">Home</span></a>

</li>
<li>
<a href="#"><span class="l"></span><span class="r"></span><span class="t">Menu Item</span></a>
<ul>
<li><a href="#">Subitem</a>
<ul>
<li><a href="#">Subitem</a></li>

<li><a href="#">Subitem</a></li>
<li><a href="#">Subitem</a></li>
</ul>
</li>
<li><a href="#">Subitem</a></li>
<li><a href="#">Subitem</a></li>
</ul>

</li>
<li>
<a href="#"><span class="l"></span><span class="r"></span><span class="t">About</span></a>
</li>
</ul>


</body>
</html>


then the css code:


/* begin Menu */
/* menu structure */

.joann-menu a, .joann-menu a:link, .joann-menu a:visited, .joann-menu a:hover
{
text-align: left;
text-decoration: none;
outline: none;
letter-spacing: normal;
word-spacing: normal;
}

.joann-menu, .joann-menu ul
{
margin: 20px 20px auto 150px;/*THIS POSITIONS THE MENU ON THE PAGE AREA*/
padding: 0;
border: 0;
list-style-type: none;
display: block;
}

.joann-menu li
{
margin: 0;
padding: 2px;/*THIS ADDS PADDING BETWEEN THE INDIVIDUAL MENU ITEMS IN MAIN AND SUB MENU*/
border: 0;
display: block;
float: left;
position: relative;
z-index: 5;
background-color:red;/*LEAVING IN THIS BG COLOUR HELPS YOU SEE WHAT YOU ARE DOING TO YOUR MENU*/
}

.joann-menu li:hover
{
z-index: 10000;
white-space: normal;
}

.joann-menu li li
{
float: none;
}

.joann-menu ul
{
visibility: hidden;
position: absolute;
z-index: 10;
left: 0;
top: 0;
background: none;
}

.joann-menu li:hover>ul
{
visibility: visible;
top: 100%;
}

.joann-menu li li:hover>ul
{
top: 0;
left: 100%;
}

.joann-menu, .joann-menu ul
{
min-height: 0;
}

.joann-menu ul
{
background-image: none;
padding: 10px 30px 30px 30px;
margin: 0 0 0 -30px;/*THIS AFFECTS THE DISTANCE BETWEEN THE MAIN MENU AND SUB ITEMS*/
}

.joann-menu ul ul
{
padding: 30px 30px 30px 10px;
margin: -30px 0 0 -10px;/*THIS IS THE ALIGNMENT OF THE SUB-SUB-MENU*/
}


/* begin MenuItem */
.joann-menu a
{
position: relative;
display: block;
overflow: hidden;
height: 52px;
cursor: pointer;
text-decoration: none;
}

.joann-menu li
{
margin-right: 0;
margin-left: 0;
}

.joann-menu ul li
{
margin:0;
clear: both;
}


.joann-menu a .r, .joann-menu a .l
{
position: absolute;
display: block;
top: 0;
z-index: -1;
height: 93px;
background-image: url('images/buttonshadowed.png'); background-repeat:no-repeat;
}

.joann-menu a .l
{
left: 0;
right: 0;
}

.joann-menu a .r
{
width: 400px;
right: 0;
clip: rect(auto, auto, auto, 400px);
}

.joann-menu a .t
{
margin: 0px 50px 30px 10px;/*PUTS DISTANCE BETWEEN THE MAIN MENU BUTTONS*/
color: #330578;
padding: 30px 50px 0px 0px;/*PUTS DISTANCE AROUND THE MAIN MENU BUTTONS*/
line-height: 45px;
text-align: left;
}

.joann-menu li:hover a .l, .joann-menu li:hover a .r
{
top: 1px;/*KEEPING THIS AT ZERO STOPS THE BUTTONS FROM JUMPING ON HOVER*/
}

/* end MenuItem */

/* begin MenuSubItem */
.joann-menu ul a
{
display: block;
white-space: nowrap;
height: 30px; /*MAXIMUM HEIGHT OF SUB AND SUBSUB ITEM BOX*/
width: 180px; /*MAXIMUM WIDTH OF SUB AND SUBSUB ITEM BOX*/
overflow: hidden;
line-height: 30px;
background-color: #ffffff;
border: 1px solid #E4C144; /*BORDER FOR SUB AND SUBSUB ITEM BOX*/

}



.joann-menu ul a, .joann-menu ul a:link, .joann-menu ul a:visited, .joann-menu ul a:hover
{
text-align: left; /*THIS POSITIONS THE TEXT IN THE SUB AND SUBSUB MENU ITEM BOX*/
text-indent: 12px;/*THIS MOVES THE TEXT IN FROM THE LEFT SIDE OF THE SUB AND SUBSUB ITEM BOXES*/
text-decoration: none;
line-height: 30px;
color: #0B16EF;/*TEXT COLOUR IN SUB AND SUBSUB ITEM BOX*/
margin: 1px 0px 0px 0px;/*THIS PUTS SPACE BETWEEN THE SUB AND SUBSUB ITEM BOXES*/
padding:0;/*THIS PUTS PADDING AROUND THE TEXT IN THE SUB AND SUBSUB ITEM BOXES*/
}

.joann-menu ul li:hover>a
{
color: green;/*HOVER TEXT COLOUR FOR SUB AND SUBSUB MENU ITEMS*/
border-color: #000000;/*BORDER COLOUR FOR SUB AND SUBSUB MENU HOVER BOXES*/
background-position: 0 -30px;
}


/* end MenuSubItem */




I only tried this out in Firefox so cannot guarantee for its behaviour in other browsers.
You will see that I only used your hover image for the main menu. You can stop that little hover jiggle/jump there by a simple pixel change. I have added comments to help see you through the css. I have also used colours which are not your own but changing them yourself will help you to see what each refers to. Oh No.......... how come the comments have disappeared????:(:(:(
JoAnn - in that case, I can only suggest you contact me directly so that I can zip file everything through to you.

Panic over.... I just found them in there!!!!
User 38401 Photo


Senior Advisor
10,951 posts

Oh My! Thank you so very very much Janys, most appreicated a billion times over. You surely didn't need to go through so much, but I am truly grateful that you did. Hopefully I'll work through enough of this to be able to pass some help on to others with it. Thanks :)
User 2230614 Photo


Registered User
7 posts

Redesigning my website with Coffeecup, and using CSS Drop Down menu. I have a very simple page... simple header <table> (name), then the CSS menu (horizontal drop down), then tables with pics of my art (I'm an artist). When I view in "preview", everything looks fine. When I view in browser (any of them), then first table of pics is off to the right, right behind the last item on the horizontal menu. Despite the closing </div> on the menu, and and <p> tag before the tables of pics... the first table continues to fly off to the right, behind the menu. Both fighting for same position.
How do I get a "break" between the menu and the tables, so the tables will center below the menu? I want to use this menu on every page, but need to resolve this before I continue.
Thanks for your help.
User 422767 Photo


Registered User
259 posts

MaudetheArtist wrote:
Redesigning my website with Coffeecup, and using CSS Drop Down menu. I have a very simple page... simple header <table> (name), then the CSS menu (horizontal drop down), then tables with pics of my art (I'm an artist). When I view in "preview", everything looks fine. When I view in browser (any of them), then first table of pics is off to the right, right behind the last item on the horizontal menu. Despite the closing </div> on the menu, and and <p> tag before the tables of pics... the first table continues to fly off to the right, behind the menu. Both fighting for same position.
How do I get a "break" between the menu and the tables, so the tables will center below the menu? I want to use this menu on every page, but need to resolve this before I continue.
Thanks for your help.


A link to your site would help us look at the html/css. :)

Have you tried viewing in other browsers as well?
Aren't you a little short for a Storm Trooper?
User 2230614 Photo


Registered User
7 posts

Hi Zac. Thank You! :):):)

I just uploaded the files to my server. And yes, I've tried in Mozilla and IE...both react the same.

URL is http://www.maudesart.com/testindex.html
my css file is on same director nav-menu.css

User 2230614 Photo


Registered User
7 posts

Oh great... after loading to my server... the hover effect also went away. :(
User 422767 Photo


Registered User
259 posts

Well, first thing's first: The link in your header to your .css file leads to a 404 error page instead of http://www.maudesart.com/nav-menu.css

The link in the header is http://www.maudesart.com/css/nav-menu.css
Aren't you a little short for a Storm Trooper?

Have something to add? We’d love to hear it!
You must have an account to participate. Please Sign In Here, then join the conversation.