Milonic provide full featured pull down web menus for some of the worlds largest companies
click here to see what it can do for you

Download Milonic DHTML Menu
Buy Milonic DHTML Menu

Back To Start Of Archive
Taken From The Forum: Help & Support for DHTML Menu Version 5+
Forum Topic: Click to view post
Last Updated: Saturday July 14 2012 - 06:07:17

Left and right borders for horizontal menu


Poster: firedog
Dated: Tuesday January 17 2006 - 9:15:58 GMT

Hi-

I'm sure this has been asked before, but I couldn't find the answer (at least as I understand things) in the forum.

You can see the menu in question at:
http://www.webpositioning.co.il/menus/sample-menu2.html

This is a horizontal menu. All the present definitions are in the global definitions and the style defintions of the main menu and a submenu style.

The problem I have is with the main menu. I am trying to add a border on the extreme left and right sides of the main menu, but not top and bottom borders.

In other words, borders on the outside left end of the left main menu item, and on the outside right end of the right main menu item. No border on the top or bottom of the entire menu or top or bottom of the items.

Is there a way to define this within the main menu definitions themselves, i.e. in the main menu style or in item definitons for the left and right items?

Or do I have to set up some kind of CSS?

Thanks,
Danny


Poster: Ruth
Dated: Tuesday January 17 2006 - 13:56:25 GMT

Hi,

Yes, you either need to use an image and imageposition, imagepadding etc, or set up css and use off and onclass in the first and last item.

Note that when using css the border is placed around items not the menu so you need a class which defines the left border and another to define the right border and apply them in the respective items. Place the following in the head of the document, or in your css file [getting rid of the style tags if you do the latter].

Code:
<style type="text/css">
.bord1{border-left:1px solid #ff0000;}
.bord2{border-right:1px solid #ff0000;}
</style>


then in the menu_data file in the main menu, call these using the offclass and onclass in the respective aI strings.

Code:
aI("status=Back To Home Page;text=Hotel Market;url=http://www.milonic.com/;offclass=bord1;onclass=bord1;");

aI("showmenu=MyMilonic;text=Contact Us;offclass=bord2;onclass=bord2;");


Keep in mind that these borders are placed around items, so if you put in a margin it will shift the items and make the borders sit inside the edge of the menu container.

Here is some information and samples about using css styling.

http://support.milonic.com/beginners/css_styling/

Hope this helps.

Ruth


Poster: firedog
Dated: Thursday January 19 2006 - 18:54:36 GMT

Ruth-

Thanks for the explanation - both of those methods worked!

Danny