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:28

NEWBIE Needs Help! - Autofill / dynamic 'separator' width?

Poster: ms8qt
Dated: Friday October 21 2005 - 14:19:18 BST

PLEASE READ MY FOLLOW-UP MESSAGE BELOW - NOT THIS ONE because I've found answers/solutions to all but one issue and the outstanding issue is much better explained/illustrated in my follow-up message! :)


I'm currently evaluating this 'tool' and so far it looks very good. I have a couple of things I need to achieve before I decide to get a license - I've sorted out most things by reading other threads but still need some help with the following...

My current menu displays as...


I need it to display like...


In order to do this I need to 'fix' the following things...

1) Despite setting the item width and alignment parameters appropriately the 'Sign Out' item is taking up the entire horizontal space available. I need to be able to fix the size of this to 90 pixels, and aligned on the right (next to the Home icon). As a result the other icons will (I hope) also move to the right as illustrated in the second image.

2) I've created a menu entry called 'www' (will change to an icon once I create one!) which opens a form. I don't want the down arrow icon on this menu displayed - how can I disable this JUST for this menu (I ideally still want it for the 'I want to...' menu.

3) Can you tell me where I can find out details of all available parameter syntaxes for the tooltip bolt-on module? I want to be able to change the font style/name/colour.

To help me fix the above I've copied the relevant code below...

with(milonic=new menuname("Sample mainmenu")){
aI("showmenu=I want to...;text=I want to...;itemwidth=91;align=left;");
aI("image=addweblink.gif;onfunction=showtip('Add a weblink');url=javascript:openHome('');itemwidth=25;imagealign=center;itemalign=right;");
aI("image=addfolder.gif;onfunction=showtip('Add a folder');url=javascript:openHome('');itemwidth=25;imagealign=center;itemalign=right;");
aI("showmenu=freeTextURL;text=www;onfunction=showtip('Enter a free-text website address');itemwidth=20;itemalign=right;");
aI("text=Sign Out;title=Sign Out;url=./testtarget.htm;align=right;textsize=90;");
aI("image=Home.gif;onfunction=showtip('Visit the website!');url=javascript:openHome('');itemwidth=25;imagealign=center;itemalign=right;");

MANY thanks in advance for any help you can give me.

Mark. :cry:

I've solved some but NOT ALL questions - please help!

Poster: ms8qt
Dated: Friday October 21 2005 - 22:08:32 BST

Hi all,

I've solved questions 2 and 3 that I posted in my original message but I still have an outstanding question/issue which is detailed after the answers below...

Answer to Q2) If you use the 'subimage' with no value then no image gets displayed for that particular menu in the menubar, e.g.


Answer to Q3) If you open the tooltips.js file you will see that the appearance of tooltips is relatively easy to modify

However, I still need help with one important design concept.

Maybe it's best if I explain my requirement differently to last time as I think it was a bit confusing...

I've created the following menu (a 'separator' is used and highlighted in grey)...


As you can see below the size and spacing of menu items is wrong when I make the browser window bigger...


My requirement - To have the size and spacing of menu items look the same (like that shown in the first menu picture) no matter how big or small the browser window. In order to do this I think I need to somehow make the 'separator' width dynamic so that it fills whatever the gap is between 'I want to...' and the icon menu items on the right. Is this possible? If not, is there another solution or workaround to achieve the look I want?

In this example the menu would then look like the following (edited in Photoshop!) Once this works I'll make the 'separator' background colour the same as the menubar background so that it appears invisible :)


FYI: I've used the following code...

with(milonic=new menuname("Sample mainmenuR")){
aI("showmenu=I want to...;text=I want to...;itemwidth=90;align=center;separatorwidth=110;");

Many thanks in advance for any help you can give.

Poster: Andy
Dated: Monday October 24 2005 - 11:56:26 BST


Looks like a small bug we introduced into version 5.733.

I've now done an emergency release of 5.734 to help fix this problem.

Please let me know if this helps or not

Thanks - some things are fixed BUT NOT dynamic separators...

Poster: ms8qt
Dated: Monday October 24 2005 - 12:24:40 BST

Hello Andy,

Thanks for the response and the quick fix you've posted. This fix appears to fix the issue of the itemwidth property not working properly.

However, if you look at the screenshots in my previous message you'll see that I want/need to left-align a drop-down menu and right-align other menu items. I've tried using itemalign=left and itemalign=right but all items appear left-aligned. The other way of achieving the same effect would be to have a dynamic separator that takes up as much width as possible in between the 'I want to...' drop down menu and the other items on the right. I heard it was possible to do a dynamic separator (so that when the browser window is resized the width will automatically change and the left and right-aligned items will appear as such) but can't work out how.

Any info/advice/workarounds/suggestions would really really help.

Many thanks,

Poster: Andy
Dated: Tuesday October 25 2005 - 12:48:22 BST

It's going to really help us if we can see a URL of this.

Looking at screenshots is good but it will help to be able to see your code.

-- Andy