Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Retain values of a multi select dropdown after submit

Guest
Jun 04, 2013 Jun 04, 2013

HI,

I have a requirement where use can mutli select in a dropdown and click on search , Once the search is clicked it query the db and provides the result.

My question is how to retain the values of teh mutli select dropdown, Below is the select where i have to code

<SELECT NAME="category" size = "5" multiple="multiple" id="category" onchange="validate()">

<CFLOOP QUERY="categorylist">

                                        <OPTION VALUE="#category#"<CFIF category IS thecategory> SELECTED STYLE="background-color:#app.field_highlight#"</CFIF>>#category_name#</CFLOOP>

</SELECT>

Can someone help

Thanks in Advance

TOPICS
Getting started
543
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Jun 05, 2013 Jun 05, 2013
LATEST

<cfif ListFindNoCase(theCategory, category)>

This will select each category that is listed in theCategory.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources