Hi 

I would really appreciate some advice on this problem I am having please, and would 
very much appreciate any advice/guidance on the best way to achieve.

I have a database table with  id, doctitle, docsummary and three fields called 
category1, category2 and category3.

The category1 field contains values such as E-mail, Servers etc in each record.

The category 2 field will contain values based on what the user has selected from the 
first category1, so for example if the user selected e-mail in category1 then 
category2 would have values such as Microsoft Exchange, POP3 etc. and the same from 
category3 field, the user selects these from a select list 

The user populates these fields through cascading select boxes using the 'onchange' 
function in javascript the laues of which are populated from a seperate table called 
category_menu..

That was just a bit of background.....

Now this is my current problem, in my first cfm page (tutorials.cfm) to display the 
top level categories works well, , I am using the following query and output shown 
below. This brings back all the data contained in category_menu table.

If the user clicks on the Server link for example they are taken to more options 
related to the Server field, when they click this second field they are taken to 
listings based on the second selection, (so the information is tree structured in the 
table) 

So would I would like to know is when the user reaches the bottom level in the tree 
and click that link they are taken to a listing of documents from the itdocs table 
(mentioned above) 

Do you use a cfif statement in the tutorial.cfm code below? sending the user to 
another cfm detail page with the query

<CFQUERY name="links" datasource="v8">
SELECT *
FROM itlinks
WHERE category3='#URL.category#'
</CFQUERY>

Is this actually possible or are there other ways of achieving the above? I hope you 
are following me?? The main code is shown below and is working, just need to find out 
how to build this last piece in to display the information from the itdocs table from 
the URL.category

Thanks

Ian

---------------------TUTORIAL.CFM---------------------------

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">

<html>
<head>
 <title>Untitled</title>
 <CFQUERY name="query1" datasource="intranetv8">
SELECT 
* from category_menu
where parent_level=
(select catno from category_menu where category='#URL.category#')
</CFQUERY>
</head>

<body>
  <cfoutput query="query1">


      
<a 
href="http://intranet.neath-porttalbot.gov.uk/testpages/itnet/test.cfm?category=#category#";
 class="homeaa">#category#</a> 
<br>
Description here 
<br>
</cfoutput>
<BR>





</body>
</html> 




~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
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
This list and all House of Fusion resources hosted by CFHosting.com. The place for 
dependable ColdFusion Hosting.

Reply via email to