unfortunately the site is behind one of those firewall things on our Intranet.  Here 
are some code snipps though to show the general gist.  The SQL should give you an idea 
of the table structure.  This snippet builds one menu item in the menu enititled 
'Employees'.  Each link in the drop down is goverened byt this SQL.  The Menu itself 
has 6 items on it.  So we run 6 SQLs like below to generate the whole menu.

<!--- queries to populate the menus --->
<cfquery name="employees" datasource="#request.datasource#" 
cachedwithin="#createtimespan(0,0,request.cachetime,0)#">
        SELECT secmain.element, secelements.path
        FROM secmain, secelements, secmenugroups
        WHERE (    (secelements.element = secmain.element)
        AND (secmenugroups.menugroupid = secelements.menugroupid)
                AND (secmain.groupid = '#request.groupid#' OR secmain.groupid = '99') 
                AND (secelements.type = 'M')
                AND (secmenugroups.MENUNAME = 'Employee')
       )
        ORDER BY element
</cfquery>

snip....
 do all the coolmenus style def stuff here
/snip

<!---now build a menu item  --->
oCMenu.makeMenu('top0','','> Employee','','','70')
<cfoutput query="employees">
        oCMenu.makeMenu('sub0#evaluate(employees.currentrow - 
1)#','top0','#employees.element#','#request.ROOTURL##request.root#/#employees.path#', 
'_top')
</cfoutput>


Doug


>-----Original Message-----
>From: Jeff [mailto:[EMAIL PROTECTED]
>Sent: Tuesday, June 03, 2003 11:31 AM
>To: CF-Talk
>Subject: Re: Context Sensitive, dynamic navigation include? How to
>accomplish?
>
>
>on 6/3/03 11:25 AM, [EMAIL PROTECTED] at 
>[EMAIL PROTECTED]
>wrote:
>
>> sure, we do this using coolmenus from dhtmlcentral.com.  We 
>store all menu
>> items in a DB.  Tables store the actual menuitem and 
>security information on
>> each item granting different roles access to different 
>items.  The menu is
>> then generated via a customtag/include.  Works well.  the 
>application.cfm file
>> is no place for this.  We usually include it on each page 
>requiring the
>> menu...more control this way.  Each call hits the DB with 
>some queries, cached
>> for performance, then loop over the queries building the menus.
>> 
>> Doug
>
>Do you have a page with an example? This sounds intriguing...
>
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq

Host with the leader in ColdFusion hosting. 
Voted #1 ColdFusion host by CF Developers. 
Offering shared and dedicated hosting options. 
www.cfxhosting.com/default.cfm?redirect=10481

                                Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
                                

Reply via email to