Overmyhead2
Programmer
I have 2 related list boxes that work. The second box show a list of dates for the user to choose. How do now display a table containing the date chosen and it's related fields? Here is my code:
<CFFORM ACTION="#CGI.SCRIPT_NAME#" METHOD="Post">
<CFIF IsDefined('form.Select_Category')>
<cfset page.Select_Category=form.Select_Category>
</cfif>
<cfoutput>
<form name="DropDown" method="post">
<cfquery datasource="DSN" username="username" password="password" name="get_Category">
SELECT *
FROM categories
</cfquery>
<!--- Display in a drop-down list --->
<SELECT NAME="Select_Category" REQUIRED="YES" ONCHANGE="this.form.submit()">
<option>Select Category </option>
<cfloop query="get_Category">
<option value='#category#'<cfif isDefined('form.Select_Category')><cfif form.select_category
eq #category#>selected</cfif></cfif>>#category#</option>
</cfloop>
</SELECT>
<cfif isDefined('page.Select_Category')>
<cfquery name="get_OrderDate" datasource="DSN" username="username" password="password">
Select * From #page.select_category#
Where SiteID=#SESSION.Auth.SiteID#
</cfquery>
<select name="select_OrderDate" required="yes" >
<option>Select OrderDate</option>
<cfloop query="get_OrderDate">
<option value="#OrderDate#"><cfif isDefined('page.Select_Category')>
<cfif page.select_category eq #OrderDate#>selected</cfif></cfif>>#OrderDate#</option>
</cfloop>
</select>
</cfif>
</cfoutput>
Really appreciate any help..
Victoria
Victoria
<CFFORM ACTION="#CGI.SCRIPT_NAME#" METHOD="Post">
<CFIF IsDefined('form.Select_Category')>
<cfset page.Select_Category=form.Select_Category>
</cfif>
<cfoutput>
<form name="DropDown" method="post">
<cfquery datasource="DSN" username="username" password="password" name="get_Category">
SELECT *
FROM categories
</cfquery>
<!--- Display in a drop-down list --->
<SELECT NAME="Select_Category" REQUIRED="YES" ONCHANGE="this.form.submit()">
<option>Select Category </option>
<cfloop query="get_Category">
<option value='#category#'<cfif isDefined('form.Select_Category')><cfif form.select_category
eq #category#>selected</cfif></cfif>>#category#</option>
</cfloop>
</SELECT>
<cfif isDefined('page.Select_Category')>
<cfquery name="get_OrderDate" datasource="DSN" username="username" password="password">
Select * From #page.select_category#
Where SiteID=#SESSION.Auth.SiteID#
</cfquery>
<select name="select_OrderDate" required="yes" >
<option>Select OrderDate</option>
<cfloop query="get_OrderDate">
<option value="#OrderDate#"><cfif isDefined('page.Select_Category')>
<cfif page.select_category eq #OrderDate#>selected</cfif></cfif>>#OrderDate#</option>
</cfloop>
</select>
</cfif>
</cfoutput>
Really appreciate any help..
Victoria
Victoria