Results 1 to 3 of 3

Thread: omnislide-vertical position top menu

  1. #1
    Join Date
    Feb 2008
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default omnislide-vertical position top menu

    1) Script Title: omnislide

    2) Script URL (on DD): http://www.dynamicdrive.com/dynamici...lide/index.htm

    3) Describe problem:
    I'm using "omnislide" top menu. However, I want the menu not to be at the very top but a couple of inches down the page. How do I do that?

    Thanks,
    Jim

  2. #2
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    30,495
    Thanks
    82
    Thanked 3,449 Times in 3,410 Posts
    Blog Entries
    12

    Default

    I'm hoping that you know your way around a text-only editor when working with HTML code. If so, you can use design mode for the menu and get its styles and HTML. Copy that to your page and modify it, then use that instead of the script generated styles and markup.

    Alternatively, with just a simple style addition, the menu may be moved down, but something else in your layout will need to cover the top portion of it.

    Like, say the menu's id is menu2, as configured in the menuItems.js file:

    Code:
     . . . UIRED!! do not edit or remove
    
    menu[2] = {  // REQUIRED!!  This menu explicitly declares all available options even if they are the same as the defaults
    id:'menu2', //use unique quoted id (quoted) REQUIRED!!
    //////////////////// . . .
    Then you can add a style section below the scripts in the head of your page:

    Code:
    <script src="mmenu.js" type="text/javascript"></script>
    <script src="menuItems.js" type="text/javascript">
    
    /***********************************************
    * Omni Slide Menu script - © John Davenport Scheuer: http://home.comcast.net/~jscheuer1/
    * very freely adapted from Dynamic-FX Slide-In Menu (v 6.5) script- by maXimus
    * This notice MUST stay intact for legal use
    * Visit Dynamic Drive at http://www.dynamicdrive.com/ for full original source code
    ***********************************************/
    
    </script>
    
    <style type="text/css">
    #menu2 {
    top:40px;
    }
    </style>
    Then you just need to have something else on your page that is fixed positioned with a z-index over 100, something like so to cover the part of it you don't want to see:

    Code:
    #some_other_id {
    position:fixed;
    z-index:101;
    top:0;
    height:40px;
    width:100%;
    background-color:white;
    }
    Except for IE 6, which would need absolute positioning and an expression, something like:

    Code:
    <!--[if lte IE 6]>
    <script type="text/javascript">
    function ie_st(){
    return document.documentElement.scrollTop+'px';
    }
    </script>
    <style type="text/css">
    #some_other_id {
    position:absolute;
    top:expression(ie_st());
    }
    </style>
    
    <![endif]-->
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

  3. #3
    Join Date
    Feb 2008
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Thanks much!!!!!!!!!!!

    Jim

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •