Layered or Fly Out Menus
Using Microsoft Expression Web to Create Flyout Menus
Create a main menu layer and give it a
z-index = 3.
Do this: Task Pane ⇒
Layers and then click on the
Draw Layer button.
Click inside this layer and insert the main menu buttons.
Do this: Insert ⇒
Interactive Button
Resize the main menu layer around the buttons
Select the main menu on the
Layer task pane and click on
Insert Layer button
Insert submenu interactive buttons into this new layer
just inserted. Name the buttons
and specify links as you go.
Repeat steps 4-6 for other submenus
Position the submenus over the
mainMenu, near the buttons
which they are related to
Position the
mainMenu on the page where it should go.
(The submenus will automatically be moved as well)
Create a behavior for the
mainMenu button to display
the corresponding submenu layer – onmouseover event.
Create a behavior for each button in the submenu to
display the submenu layer they are in – onmouseover.
Create a behavior for the submenu layer to hide it –
onmouseout event.
Create behaviors for the buttons on the
mainMenu next to the one you
are now working on, to hide the submenu – onmouseover.
Create a behavior for the
mainMenu layer to hid this
same submenu – onmouseout.
Click on the “eyeball” for the submenu to give it a
default status of hidden/invisible.
Repeat steps 10-15 for each
mainMenu button.
Adding Behaviors to Buttons and Layers
To add a behavior to a button or a layer, first select Task Panes è
Behaviors to make sure the task pane for Behaviors is active.
Select a button or layer.
In behaviors task pane, click on the
Insert button.
Select Change
Properties from the Behaviors
menu.
Select the
Select Element radio button option.
Select div
from the element type dropdown (this is the “layer” element type)
Select the submenu to be displayed by this
mainMenu button from the
Element ID dropdown.
Click the
Visibility button
Select Visible
or Invisible radio button.
(Make sure the “Restore on Mouseout Event” checkbox is unchecked.)
Click OK to
add the behavior.
Change “onclick”
to “onmouseover” or “onmouseout”
in the event column of the behavior task pane.
Behaviors to Add for Each Submenu
|
Button |
Action |
Event |
|
1. Button on mainmenu |
display the submenu |
onmouseover |
|
2. Buttons on submenu |
display the submenu |
onmouseover |
|
3. Layer for submenu |
display the submenu |
onmouseover |
|
4. Layer for submenu |
hide the submenu |
onmouseout |
|
5. Buttons for mainmenu |
hide the submenu |
onmouseover |
|
6. Layer for mainmenu |
hide the submenu |
onmuuseout |