Gary Menzel wrote:
That error means you are not calling the code under the FarCry framework. Almost everything in FarCry is driven by index.cfm (which then includes the right layers of code to make your pages display correctly).
You need to put the code in a file (e.g. menu.cfm - in maybe <your app>/webskin/includes directory) and call it as follows:
<cfmodule template="/farcry/#application.applicationname#/webskin/includes/menu.cfm">
You would need to put this call in a template page (e.g. displaypageLanding.cfm or displaypageStandard.cfm or your own template) in your <your app>/webskin/dmHTML directory and make sure the page you are viewing uses that template (via the Admin console).
Make sure you add the modifications that Ben posted along with my update of swapping around the current and previous variables (or Ben's abs() around the expression).
NOTE: unless you have created the styles that Ben has embedded into the code, all you will see is a <UL> object that displays the navigation down to the point you are viewing.
To test the code properly you will need to create several nested navigation nodes each with a dmHTML page underneath it.
2nd NOTE: the code is NOT a menuing system. It is meant to demonstrate how to use some of the tree methods to obtain the navigation items and how to display them using an unordered list.
Regards, Gary Menzel
-----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Brant Winter Sent: Monday, 26 January 2004 8:48 AM To: FarCry Developers Subject: [farcry-dev] Re: Drop down menus on farcy website
Ben - I am currently trying to pull apart that code, but I cannot get it to do anything? Please excuse my ignorance, but I am getting a CF debug screen when I try and preview the page with the code that you published.
Element NAVID is undefined in REQUEST.
The error occurred in C:\Inetpub\applications\hocacms\www\index2.cfm: line 12
10 : <cfscript> 11 : if(not isDefined("attributes.navID")) // allows a navID to be passed in, overiding request.navID 12 : attributes.navID=request.navID; 13 : // Check for Friendly URL 14 : if(application.config.plugins.fu)
I have just stuck the code that you pubished in a .cfm page to see if I can get started with it, do I need to view it with a URL variable ,
?objectid=xxxxxxx
Brant
--- You are currently subscribed to farcry-dev as: [EMAIL PROTECTED] To unsubscribe send a blank email to [EMAIL PROTECTED]
MXDU2004 + Macromedia DevCon AsiaPac + Sydney, Australia http://www.mxdu.com/ + 24-25 February, 2004
