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

Cold Fusion


Poster: WebMatt
Dated: Monday February 16 2004 - 22:00:13 GMT

I'm using Cold Fusion and using frames. Is it possible to use Milonic. I've tried to plug in the Milonic files and update the menu_data.js. I can't get a menu to display yet. We're not supporting NS as of now so we dropped the Netscape file. Do you have an idea of what I need to do to get this functioning? :oops:


Poster: John
Dated: Monday February 16 2004 - 22:05:02 GMT

http://westcgi.west.asu.edu/sai/ will show you a CF site.

I made the menu file calls an include (a .cfm file), which looks like this...
Code:
<script language="JavaScript" src="/sai/templates/menu5/milonic_src.js" type="text/javascript"></script>   
<script language="JavaScript" type="text/javascript">
if(ns4)_d.write("<scr"+"ipt language=JavaScript src=/sai/templates/menu5/mmenuns4.js><\/scr"+"ipt>");
else _d.write("<scr"+"ipt language=JavaScript src=/sai/templates/menu5/mmenudom.js><\/scr"+"ipt>");</script>
<script language="JavaScript" src="/sai/templates/menu5/xp_data.cfm" type="text/javascript"></script>

The _data file is 'standard' - just change the suffix to .cfm.


Poster: WebMatt
Dated: Monday February 16 2004 - 22:05:03 GMT

I wanted to add that I'm geting the following error: object expected line 24. The IE script debugger shows that the following command failed:
_drawMenu(_a,1). HTH.


Poster: John
Dated: Monday February 16 2004 - 22:05:51 GMT

URL?


Poster: WebMatt
Dated: Tuesday February 17 2004 - 16:55:52 GMT

First off, thanks for the quick response! :D Unfortunately I'm behind the firewall in a development environment. I did change the data_menu.js to data_menu.cfm. To simplify things I just created a main menu with one menu text item and 2 menu selections. I still got the error (see my first message of the topic thread) when it tried to draw the menu. Here's the code:

<CFOUTPUT>
<SCRIPT language=JavaScript src="#app.JavaScript#milonic_src.js" type="text/javascript"></SCRIPT>
<SCRIPT language=JavaScript src=#app.JavaScript#mmenudom.js" type="text/javascript"></SCRIPT>

<script>

_menuCloseDelay=500 // The time delay for menus to remain visible on mouse out
_menuOpenDelay=150 // The time delay before menus open on mouse over
_followSpeed=5 // Follow scrolling speed
_followRate=40 // Follow scrolling Rate
_subOffsetTop=10 // Sub menu top offset
_subOffsetLeft=-10 // Sub menu left offset
_scrollAmount=3 // Only needed for Netscape 4.x
_scrollDelay=20 // Only needed for Netcsape 4.x



with(menuStyle=new mm_style()){
onbgcolor="4F8EB6";
oncolor="ffffff";
offbgcolor="DCE9F0";
offcolor="515151";
bordercolor="296488";
borderstyle="solid";
borderwidth=1;
separatorcolor="2D729D";
separatorsize="1";
padding=5;
fontsize="75%";
fontstyle="normal";
fontfamily="Verdana, Tahoma, Arial";
pagecolor="black";
pagebgcolor="82B6D7";
headercolor="000000";
headerbgcolor="ffffff";
subimage="arrow.gif";
subimagepadding="2";
overfilter="Fade(duration=0.2);Alpha(opacity=90);Shadow(color='777777', Direction=135, Strength=5)";
outfilter="randomdissolve(duration=0.3)";
}

with(milonic=new menuname("Main Menu")){
style=menuStyle;
top=10;
left=10;
alwaysvisible=1;
orientation="horizontal";
aI("text=Students;show-menu=Students;status=Student Search and Updating;");

}


with(milonic=new menuname("Students")){
style=menuStyle;
overflow="scroll";
aI("text=Student Search;url=/students/student_search.cfm?#app.Token#;");
aI("text=Add New Student;url=/students/student_input.cfm?#app.Token#&Action=add");
}

drawMenus();
</script>

</CFOUTPUT>


Poster: John
Dated: Tuesday February 17 2004 - 17:23:57 GMT

Took your code, messed with it a bit, LINK REMOVED Displays fine.

Note the following...

1. Took the code out of the main page and put it back in its own file. This is called by the include (which, of course, you'll see in full with a view source).

2. show-menu= is incorrect. Changed to showmenu=. That's why you didn't see the sub.

3. Removing the <cfoutput> (because of the code move to its own file) made the entire menu show up.

In my example there really isn't too much CF going on, but I handled it this way...
Code:
aI("text=Browser: <cfoutput>#cgi.http_user_agent#</cfoutput>;image=/sai/graphics/xpblank.gif;");

etc.

I would recommend leaving the NS call in place. You may not be supporting it, but you never know who's going to hit the site with what.


Poster: WebMatt
Dated: Tuesday February 17 2004 - 17:59:55 GMT

Thanks again for the quick response. Could you send the code for the menu_data.cfm. I'm still having the same problem when it tried to draw the menu. I'm wondering whether the size of the navigation bar has anything to do with it. Can the menu be drawn over a different frame. The navigation frame only takes up a few pixels in height albeit I would have thought that the menu item would display even if menu options did not.


Poster: John
Dated: Tuesday February 17 2004 - 18:10:06 GMT

WebMatt wrote:
Could you send the code for the menu_data.cfm.

Code:
_menuCloseDelay=500 // The time delay for menus to remain visible on mouse out
_menuOpenDelay=150 // The time delay before menus open on mouse over
_followSpeed=5 // Follow scrolling speed
_followRate=40 // Follow scrolling Rate
_subOffsetTop=10 // Sub menu top offset
_subOffsetLeft=-10 // Sub menu left offset
_scrollAmount=3 // Only needed for Netscape 4.x
_scrollDelay=20 // Only needed for Netcsape 4.x

with(menuStyle=new mm_style()){
onbgcolor="#4F8EB6";
oncolor="#ffffff";
offbgcolor="#DCE9F0";
offcolor="#515151";
bordercolor="#296488";
borderstyle="solid";
borderwidth=1;
separatorcolor="#2D729D";
separatorsize=1;
padding=5;
fontsize="75%";
fontstyle="normal";
fontfamily="Verdana, Tahoma, Arial";
pagecolor="black";
pagebgcolor="#82B6D7";
headercolor="#000000";
headerbgcolor="#ffffff";
subimage="arrow.gif";
subimagepadding="2";
overfilter="Fade(duration=0.2);Alpha(opacity=90);Shadow(color='777777', Direction=135, Strength=5)";
outfilter="randomdissolve(duration=0.3)";
}

with(milonic=new menuname("Main Menu")){
style=menuStyle;
top=10;
left=10;
alwaysvisible=1;
orientation="horizontal";
aI("text=Students;showmenu=Students;status=Student Search and Updating;");
}

with(milonic=new menuname("Students")){
style=menuStyle;
overflow="scroll";
aI("text=Student Search;url=/students/student_search.cfm?#app.Token#;");
aI("text=Add New Student;url=/students/student_input.cfm?#app.Token#&Action=add");
}

drawMenus();

WebMatt wrote:
I'm still having the same problem when it tried to draw the menu. I'm wondering whether the size of the navigation bar has anything to do with it. Can the menu be drawn over a different frame.

Sorry, I missed 'frames' in your initial post. v5 is not frames-friendly, and no, you can't draw from one frame into another (I think that's what you're asking).

One of the team posted some unsupported frames code for v5. Do a search to locate the topic.


Poster: WebMatt
Dated: Tuesday February 17 2004 - 20:07:16 GMT

Thanks. I've been trying to get the suggested unsupported code to work but with not much luck as of yet. In the meantime, our original objective is to avoid bleeding in version 3. When I converted the code from version 3 to version 5, we ran into syntax errors. Is there a simple way to just overcome the bleeding problem in version 3 ? (we have 3.4) It only bleeds through on a selection element. The selection shows through the menu drop down. I couldn't find a post on that issue.