Ask a Question related to Coldfusion Database Access, Design and Development.
-
quiero mas #1
drop down menu probs again
Hi Everyone - I had this drop down menu working fine then ive somehow disturbed
it and it wont work properly
I want a user to be able to choose an item from each menu then search by that
query. If i have chosen something in every menu it does a search but simple
pulls the whole list in regards to the Area search. Sorry to mikerroo who
initially helped me solve this - i have been back many times but have stuffed
something up.
I also want the user to be able to choose 'any'
<cfparam name="PageNum_get_area" default="1">
<cfparam name="PageNum_urlpass" default="1">
<!--- check that an area and langauge were selected, if not return to the
previous page --->
<CFIF form.area EQ '' or Form.language EQ '' or Form.Department EQ''>
<CFLOCATION URL="healthsapporoindex.cfm">
<CFABORT>
</CFIF>
<!--- all good, so do query --->
<cfquery name="urlpass" datasource="dependent">
SELECT hospital_name, hospital_id, EnglishAddress, JapaneseAddress, NihongoName
FROM tHHbyL
WHERE group_id = '#form.area#'
<!--- Either select a specific language or ALL languages. --->
<CFIF IsNumeric (form.Language)>
AND language_id = <CFQUERYPARAM cfsqltype="cf_sql_integer"
value=#form.Language#>
AND department_id = <CFQUERYPARAM cfsqltype="cf_sql_integer"
value=#form.Department#></CFIF>
</cfquery>
Menu code
<li> <div id="SELECT" > <FORM ACTION="dropdownresult.cfm" METHOD="POST"
Name="myform">
<div align="center"><BR>
<select name="Area" >
<option value="">Area</option>
<option value="Chuo Ku">Chuo Ku</option>
<option value="Shiroishi Ku">Shiroishi</option>
<option value="Teine Ku">Teine Ku</option>
<option value="Minami Ku">Minami Ku</option>
<option value="Kita Ku">Kita Ku</option>
<option value="Higashi Ku">Higashi Ku</option>
<option value="Nishi Ku">Nishi Ku</option>
<option value="Kiyouta Ku">Kiyouta Ku</option>
</select>
<BR>
<BR>
<SELECT NAME="Language" SIZE="1">
<OPTION VALUE="">Language</OPTION>
<option value="any">ANY</option>
<OPTION VALUE="English">English</OPTION>
<OPTION VALUE="Spanish">Spanish</OPTION>
<OPTION VALUE="Portuguese">Portuguese</OPTION>
<OPTION VALUE="Japanese">Japanese</OPTION>
<OPTION VALUE="Korean">Korean</OPTION>
<OPTION VALUE="Russian">Russian</OPTION>
<OPTION VALUE="Tagalog">Tagalog</OPTION>
</SELECT>
<BR>
<BR>
<SELECT NAME="Department" SIZE="1" >
<OPTION VALUE="">Department</OPTION>
<option value="any">ANY</option>
<OPTION VALUE="Allergy Specialist">Allergy Specialist</OPTION>
<OPTION VALUE="Anethesiology">Anethesiology</OPTION>
<OPTION VALUE="Bronchoesopagology">Bronchoesopagology</OPTION>
<OPTION VALUE="Cardiology">Cardiology</OPTION>
<OPTION VALUE="Cardiosurgery">Cardiosurgery</OPTION>
<OPTION VALUE="Dentristry">Dentristry</OPTION>
<OPTION VALUE="Dental&OralSurgery">Dental Surgery</OPTION>
<OPTION VALUE="Dermatology">Dermatology</OPTION>
<OPTION VALUE="Emergency">Emergency</OPTION>
<OPTION VALUE="GeneralHospital">General Hospital</OPTION>
<OPTION VALUE="Gynecology">Gynecology</OPTION>
<OPTION VALUE="InternalMedicine">Internal Medicine</OPTION>
<OPTION VALUE="Neurology">Neurology</OPTION>
<OPTION VALUE="Neurosurgery">Neurosurgery</OPTION>
<OPTION VALUE="Obstetrics">Obstetrics</OPTION>
<OPTION VALUE="Ophthalmology">Ophthalmology</OPTION>
<OPTION VALUE="Orthopedics">Orthopedics</OPTION>
<OPTION VALUE="Otolaryngology">Otolaryngology</OPTION>
<OPTION VALUE="Pediatrics">Pediatrics</OPTION>
<OPTION VALUE="PediatricDentristry">Pediatric Dentristry</OPTION>
<OPTION VALUE="PlasticSurgery">Plastic Surgery</OPTION>
<OPTION VALUE="Proctology">Proctology</OPTION>
<OPTION VALUE="Psychiatrics">Psychiatrics</OPTION>
<OPTION VALUE="Psyschosomatic">Psyschosomatic</OPTION>
<OPTION VALUE="Pulmonology">Pulmonology</OPTION>
<OPTION VALUE="Rehabilitation">Rehabilitation</OPTION>
<OPTION VALUE="Resuscitology">Resuscitology</OPTION>
<OPTION VALUE="Surgery">Surgery</OPTION>
<OPTION VALUE="Urology">Urology</OPTION>
<OPTION VALUE="Venerology">Venerology</OPTION>
</SELECT>
quiero mas Guest
-
Drop Down Menu for Pay Pal
I just signed up for Pay Pal to use on my order page on my web site for selling merch. In Dreamweaver, I have made a table with columns for each... -
drop down menu
Do anyone know the way to create this kinda drop down menu as shown at the right hand side, http://www.macromedia.com/software/flash/. Thanks for any... -
Drop down menu help
I've used 3 of dreamweavers drop down boxes on my page. I would like to know if its at all possible to have the selected items from the list open in... -
Drop Down Menu?
I am very new to FlashMX. (Just opened the program about a week ago and have spent time doing the lessons) Is it possible to create a mouse over... -
How do I build Drop Down menu using Menu magic with Database result
Hi Every One. I resently purched Menu Magic Dropdown System. I would like to list my database content like news( few sentense with link ), Authers... -
quiero mas #2
Re: drop down menu probs again
reeearoy thanks for your help
this is the situation
<cfparam name="PageNum_get_area" default="1">
<cfparam name="PageNum_urlpass" default="1">
<!--- check that an area and langauge were selected, if not return to the
previous page --->
<CFIF form.area EQ '' or Form.language EQ '' or Form.Department EQ ''>
<CFLOCATION URL="healthsapporoindex.cfm">
<CFABORT>
</CFIF>
<!--- all good, so do query --->
<cfquery name="urlpass" datasource="dependent">
SELECT hospital_name, hospital_id, EnglishAddress, JapaneseAddress, NihongoName
FROM tHHbyL
WHERE group_id = '#form.area#'
<!--- Either select a specific language or ALL languages. --->
AND language_id = <CFQUERYPARAM cfsqltype="cf_sql_varchar"
value=#form.Language#>
AND department_id = <CFQUERYPARAM cfsqltype="cf_sql_varchar"
value=#form.Department#>
</cfquery>
Still can't get the query to do what i want - no error just want do a search
like this
area chuo ku
language any
department emergency
if i search like this i get results - but i get all the records for Chuo ku
Regards Mark
quiero mas Guest



Reply With Quote

