Reply
Spry menu bar question
Old 03-07-2008, 02:28 PM Spry menu bar question
Skilled Talker

Posts: 65
I've got a horizontal Spry menu bar and one button has one drop down.

How do I get the drop down button to be the same width as the one on top? The word may be smaller...but I want the buttons the same width.

When I select "auto" it puts what looks like a teeny weeny scroll bar to the right of the button.
missingtime is offline
Reply With Quote
View Public Profile
 
When You Register, These Ads Go Away!
Old 03-07-2008, 02:51 PM Re: Spry menu bar question
Gilligan's Avatar
Dead Like Me

Posts: 1,608
Name: Stefan
Location: London, UK
Spry menu??? What's that?

if its as simple as a select menu, then use

Code:
<select size="yoursize">
Gilligan is offline
Reply With Quote
View Public Profile
 
Old 03-07-2008, 03:32 PM Re: Spry menu bar question
Skilled Talker

Posts: 65
Quote:
Originally Posted by Gilligan View Post
Spry menu??? What's that?
It's a Dreamweaver widget.
missingtime is offline
Reply With Quote
View Public Profile
 
Old 03-07-2008, 04:10 PM Re: Spry menu bar question
Gilligan's Avatar
Dead Like Me

Posts: 1,608
Name: Stefan
Location: London, UK
okay, should be easy enough...can i see the code?
Gilligan is offline
Reply With Quote
View Public Profile
 
Old 03-08-2008, 01:59 AM Re: Spry menu bar question
Skilled Talker

Posts: 65
Quote:
Originally Posted by Gilligan View Post
okay, should be easy enough...can i see the code?
Here's the CSS. I need to make the submenus inherit their width from the parent menu. I've tried fiddling with it but couldn't get it done.

***************

@charset "UTF-8";

/* SpryMenuBarHorizontal.css - Revision: Spry Preview Release 1.4 */

/* Copyright (c) 2006. Adobe Systems Incorporated. All rights reserved. */

/************************************************** *****************************

LAYOUT INFORMATION: describes box model, positioning, z-order

************************************************** *****************************/

/* The outermost container of the Menu Bar, an auto width box with no margin or padding */
ul.MenuBarHorizontal
{
margin: 0;
padding: 0;
list-style-type: none;
font-size: 100%;
cursor: default;
width: auto;
height: auto;
}
/* Set the active Menu Bar with this class, currently setting z-index to accomodate IE rendering bug: http://therealcrisp.xs4all.nl/meuk/IE-zindexbug.html */
ul.MenuBarActive
{
z-index: 1000;
}
/* Menu item containers, position children relative to this container and are a fixed width */
ul.MenuBarHorizontal li
{
margin: 0;
padding: 0;
list-style-type: none;
font-size: 100%;
position: relative;
text-align: left;
cursor: pointer;
width: auto;
float: left;
}
/* Submenus should appear below their parent (top: 0) with a higher z-index, but they are initially off the left side of the screen (-1000em) */
ul.MenuBarHorizontal ul
{
margin: 0;
padding: 0;
list-style-type: none;
font-size: 100%;
z-index: 1020;
cursor: default;
width: 61px;
position: absolute;
left: -1000em;
}
/* Submenu that is showing with class designation MenuBarSubmenuVisible, we set left to auto so it comes onto the screen below its parent menu item */
ul.MenuBarHorizontal ul.MenuBarSubmenuVisible
{
left: auto;
border-left-width: 0px;
border-left-style: none;
border-top-width: 0px;
border-right-width: 0px;
border-bottom-width: 0px;
border-top-style: none;
border-right-style: none;
border-bottom-style: none;
}
/* Menu item containers are same fixed width as parent */
ul.MenuBarHorizontal ul li
{
width: 66px;
border-top-width: 0px;
border-right-width: 0px;
border-bottom-width: 0px;
border-left-width: 0px;
border-top-style: none;
border-right-style: none;
border-bottom-style: none;
border-left-style: none;
}
/* Submenus should appear slightly overlapping to the right (95%) and up (-5%) */
ul.MenuBarHorizontal ul ul
{
position: absolute;
margin: -5% 0 0 95%;
}
/* Submenu that is showing with class designation MenuBarSubmenuVisible, we set left to 0 so it comes onto the screen */
ul.MenuBarHorizontal ul.MenuBarSubmenuVisible ul.MenuBarSubmenuVisible
{
left: auto;
top: 0;
}

/************************************************** *****************************

DESIGN INFORMATION: describes color scheme, borders, fonts

************************************************** *****************************/

/* Submenu containers have borders on all sides */
ul.MenuBarHorizontal ul
{
border: 1px solid #CCC;
}
/* Menu items are a light gray block with padding and no text decoration */
ul.MenuBarHorizontal a
{
display: block;
cursor: pointer;
background-color: #FFFF33;
padding: 0.5em 0.75em;
color: #152D6A;
text-decoration: none;
border-right-width: 1px;
border-bottom-width: 1px;
border-right-style: solid;
border-bottom-style: solid;
border-right-color: #000000;
border-bottom-color: #000000;
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 11px;
font-weight: bold;
border-top-style: none;
}
/* Menu items that have mouse over or focus have a blue background and white text */
ul.MenuBarHorizontal a:hover, ul.MenuBarHorizontal a:focus
{
background-color: #FF0000;
color: #FFF;
border: 1px solid #000000;
}
/* Menu items that are open with submenus are set to MenuBarItemHover with a blue background and white text */
ul.MenuBarHorizontal a.MenuBarItemHover, ul.MenuBarHorizontal a.MenuBarItemSubmenuHover, ul.MenuBarHorizontal a.MenuBarSubmenuVisible
{
background-color: #FF0000;
color: #FFF;
}

/************************************************** *****************************

SUBMENU INDICATION: styles if there is a submenu under a given menu item

************************************************** *****************************/

/* Menu items that have a submenu have the class designation MenuBarItemSubmenu and are set to use a background image positioned on the far left (95%) and centered vertically (50%) */
ul.MenuBarHorizontal a.MenuBarItemSubmenu
{
background-image: url(SpryMenuBarDown.gif);
background-repeat: no-repeat;
background-position: 95% 50%;
padding-right: 20px;
}
/* Menu items that have a submenu have the class designation MenuBarItemSubmenu and are set to use a background image positioned on the far left (95%) and centered vertically (50%) */
ul.MenuBarHorizontal ul a.MenuBarItemSubmenu
{
background-image: url(SpryMenuBarRight.gif);
background-repeat: no-repeat;
background-position: 95% 50%;
}
/* Menu items that are open with submenus have the class designation MenuBarItemSubmenuHover and are set to use a "hover" background image positioned on the far left (95%) and centered vertically (50%) */
ul.MenuBarHorizontal a.MenuBarItemSubmenuHover
{
background-image: url(SpryMenuBarDownHover.gif);
background-repeat: no-repeat;
background-position: 95% 50%;
border-left-width: 0px;
border-left-style: none;
border-top-width: 0px;
border-right-width: 0px;
border-bottom-width: 0px;
border-top-style: none;
border-right-style: none;
border-bottom-style: none;
}
/* Menu items that are open with submenus have the class designation MenuBarItemSubmenuHover and are set to use a "hover" background image positioned on the far left (95%) and centered vertically (50%) */
ul.MenuBarHorizontal ul a.MenuBarItemSubmenuHover
{
background-image: url(SpryMenuBarRightHover.gif);
background-repeat: no-repeat;
background-position: 95% 50%;
border-left-width: 0px;
border-left-style: none;
border-top-width: 0px;
border-right-width: 0px;
border-bottom-width: 0px;
border-top-style: none;
border-right-style: none;
border-bottom-style: none;
}

/************************************************** *****************************

BROWSER HACKS: the hacks below should not be changed unless you are an expert

************************************************** *****************************/

/* HACK FOR IE: to make sure the sub menus show above form controls, we underlay each submenu with an iframe */
ul.MenuBarHorizontal iframe
{
position: absolute;
z-index: 1010;
}
/* HACK FOR IE: to stabilize appearance of menu items; the slash in float is to keep IE 5.0 from parsing */
@media screen, projection
{
ul.MenuBarHorizontal li.MenuBarItemIE
{
display: inline;
f\loat: left;
background: #FFF;
}
}
missingtime is offline
Reply With Quote
View Public Profile
 
Old 03-08-2008, 07:53 AM Re: Spry menu bar question
Gilligan's Avatar
Dead Like Me

Posts: 1,608
Name: Stefan
Location: London, UK
Can I have the HTML code as well, need to know what kind of code the menu uses.
Gilligan is offline
Reply With Quote
View Public Profile
 
Old 03-08-2008, 11:16 AM Re: Spry menu bar question
Skilled Talker

Posts: 65
Quote:
Originally Posted by Gilligan View Post
Can I have the HTML code as well, need to know what kind of code the menu uses.
Here it is:

<ul id="MenuBar1" class="MenuBarHorizontal">
<li><a href="one.html"> One</a></li>
<li><a href="two.html">Two</a></li>
<li><a href="three.html">Three</a></li>
<li><a href="four.html">Four</a></li>
<li><a href="five.html" class="MenuBarItemSubmenu">Five</a>
<ul>
<li><a href="five.html" target="_blank">Map</a></li>
</ul>
</li>
<li><a href="contact.html">Contact</a></li>
</ul>
missingtime is offline
Reply With Quote
View Public Profile
 
Old 03-08-2008, 12:19 PM Re: Spry menu bar question
Gilligan's Avatar
Dead Like Me

Posts: 1,608
Name: Stefan
Location: London, UK
try changing

Code:
width: auto;
to

Code:
width: inherit;

Last edited by Gilligan : 03-08-2008 at 12:20 PM.
Gilligan is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to Spry menu bar question
 

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off




   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML

 


Page generated in 0.58068 seconds with 12 queries