logo-dw

Go Back   Dreamweaver Club Forums > Dreamweaver forums > Spry
Register FAQ Members List Search Today's Posts Mark Forums Read

Reply
 
Thread Tools Display Modes
Old 06-01-2007, 09:21 PM   #1
Chris P
 
Join Date: May 2007
Posts: 10
Default Spry Widget as an include?

So I have some widgets on my site that I would like to "include" on other pages. I have 4 different template files for my site and I need to tie all of the menus together so that when I update one file they all update.

My first instinct was to package the whole menu in a file and include it. This rendered the menu but no submenus work.

The next thing I did was just throw the UL LI into the file and leave the CSS etc in the page file.

This did the same thing. Rendered the menu with all of the colors etc but leaves me with no functional submenus.

Am I going about this all wrong?
Chris P is offline   Reply With Quote
Old 06-01-2007, 09:43 PM   #2
davidj
davidj's Avatar
 
Join Date: Sep 2005
Location: The Toon (newcastle upon Tyne)
Posts: 8,256
Default

show me the code

the menus
__________________
Would you like to learn PHP from me? Check out -> www.codezenith.co.uk
davidj is offline   Reply With Quote
Old 06-04-2007, 03:37 AM   #3
chriskq
chriskq's Avatar
 
Join Date: Oct 2005
Location: Sydney - DownUnder
Posts: 798
Default

have u really used spry effects ???

http://labs.adobe.com/technologies/spry/demos/effects/

ill be so impressed if u have

for anyone that does not know what spry effects are, its essentially a javascript tweening package


__________________
can u do this with ur myspace? http://www.myspace.com/chrisjash
chriskq is offline   Reply With Quote
Old 06-04-2007, 02:02 PM   #4
Chris P
 
Join Date: May 2007
Posts: 10
Default

Code:
    <ul id="LAMenu" class="MenuBarHorizontal">
            <li><a href="#" class="MenuBarItemSubmenu">About</a>
              <ul>
                <li><a href="#">About Liquid</a></li>
                <li><a href="#">Privacy</a></li>
                <li><a href="#">TOS</a></li>
              </ul>
            </li>
            <li><a href="<A href="http://blog.liquidarchaeology.com/">Blog</a></li">http://blog.liquidarchaeology.com/">Blog</a></li>
      <li><a href="#">Resources</a></li>
            <li><a href="#">Buoys</a></li>
            <li><a class="MenuBarItemSubmenu" href="#">Projects</a>
                <ul>
                  <li><a class="MenuBarItemSubmenu" href="#">Item 3.1</a>
                      <ul>
                        <li><a href="#">Item 3.1.1</a></li>
                        <li><a href="#">Item 3.1.2</a></li>
                      </ul>
                  </li>
                  <li><a href="#">Item 3.2</a></li>
                  <li><a href="#">Item 3.3</a></li>
                </ul>
            </li>
            <li><a href="#" class="MenuBarItemSubmenu">Team</a>
                <ul>
                  <li><a href="#">Team Members</a></li>
                  <li><a href="#">Contributors</a></li>
                </ul>
            </li>
            <li><a href="#">Home</a> </li>
    </ul>
Chris P is offline   Reply With Quote
Old 06-04-2007, 02:03 PM   #5
Chris P
 
Join Date: May 2007
Posts: 10
Default

That is the menu code.
Like I said it works when in the .asp that has the rest of the content but when I put it in anouther file and call it, it shows up ok but the submenues don't work.
Chris P is offline   Reply With Quote
Old 06-04-2007, 02:06 PM   #6
davidj
davidj's Avatar
 
Join Date: Sep 2005
Location: The Toon (newcastle upon Tyne)
Posts: 8,256
Default

its like typing twins!

chris1 and chris2
__________________
Would you like to learn PHP from me? Check out -> www.codezenith.co.uk
davidj is offline   Reply With Quote
Old 06-05-2007, 03:35 AM   #7
chriskq
chriskq's Avatar
 
Join Date: Oct 2005
Location: Sydney - DownUnder
Posts: 798
Default

haha Dj (im definatly uber chris1 then)

chris2 we cant do much without looking at the CSS aswell

is ur site online to test anywhere?
__________________
can u do this with ur myspace? http://www.myspace.com/chrisjash
chriskq is offline   Reply With Quote
Old 06-05-2007, 01:58 PM   #8
Chris P
 
Join Date: May 2007
Posts: 10
Default

Sorry I guess I am having a mind melt with how busy I am.
I got the include to work. Although It doesn't render as a menu but rather a UL in design mode it does work when I publish it. ( just makes design mode looks confusing)

But I still have a little tweeking to do.

I notice that when I use these widgets the page twitches when I mose over or click on some of them.
Check out how the page twitches up a pixle or two the FIRST time you mouse over it then it is ok.
http://dev.liquidarchaeology.com/Buoys/Buoys.asp
any ideas?
here is the css.

Code:
 
@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
{
 list-style-type: none;
 font-size: 100%;
 cursor: default;
 margin-right: 1.5em;
}
/* 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
{
 list-style-type: none;
 font-size: 100%;
 position: relative;
 cursor: pointer;
 float: right;
 white-space: nowrap;
 width: 4.5em;
}
/* 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: 7em;
 position: absolute;
 left: -1000em;
 white-space: nowrap;
}
/* 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;
}
/* Menu item containers are same fixed width as parent */
ul.MenuBarHorizontal ul li
{
 float: none;
 background-color: transparent;
 width: 7em;
}
/* 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: #33C;
 color: #fff;
 text-decoration: none;
 padding-top: 0.1em;
 padding-right: 1em;
 padding-bottom: 0.1em;
 padding-left: 0.75em;
 font-family: Verdana, Arial, Helvetica, sans-serif;
 font-size: x-small;
}
/* 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: #EBEBEB;
 color: #333;
}
/* 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: #EBEBEB;
 color: #333;
}
/*******************************************************************************
 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(SpryMenuBarDownHover.gif);
 background-repeat: no-repeat;
 background-position: 95% 50%;
}
/* 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(SpryMenuBarRightHover.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(SpryMenuBarDown.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 ul a.MenuBarItemSubmenuHover
{
 background-image: url(SpryMenuBarRight.gif);
 background-repeat: no-repeat;
 background-position: 95% 50%;
}
/*******************************************************************************
 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: right;
 background: #FFF;
 }
}
Chris P is offline   Reply With Quote
Reply


Thread Tools
Display Modes

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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 01:59 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2017, vBulletin Solutions, Inc.
Copyright 2006 DreamweaverClub.com