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

multiple bind parameters in <cfselect>

New Here ,
Sep 19, 2007 Sep 19, 2007

Copy link to clipboard

Copied

hi all,
i'm trying to populate <cfselect> values using bind which takes more than one parameter.

code:
<cfselect name="selectCode"
value="selectCode"
display="selectCode"
bind="cfc:related_select.getSelectCode(pId={periodId},rCode={respCode})"
bindonload="false">

where periodId and respCode comes from another two <cfselect> dropdowns which uses bind 'ng too. which works well

problem:
when i do this <cfselect> is binding to database as many times as the number of parameters i'm passing in bind,
so if i want to bind it with 10 <cfselect> dropdown values, it is trying to bind 10 times, and because of which browser hangs

questions:
1. am i doing it in the right way?
2. is there any other way to pass multiple parameters to bind attribute

any help would be greatly appreciated

Thank you
Sanjay

TOPICS
Advanced techniques

Views

590

Translate

Translate

Report

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
LEGEND ,
Sep 19, 2007 Sep 19, 2007

Copy link to clipboard

Copied

have you heard of @none switch?
i.e.:

<cfselect
name="selectCode"
value="selectCode"
display="selectCode"

bind="cfc:related_select.getSelectCode(pId={periodId@none},rCode={respCode@none})"
bindonload="false" />

what @none does is prevents your cfselect from updating (re-binding)
itself with every change in the elements it is bound to. you can have
all params with @none, and then will need to submit the form to refresh
the cfselect; or you can have it bound without @none to one (or several)
of the elements and it will refresh with changes to that/those elements
only...

hth

--

Azadi Saryev
Sabai-dee.com
http://www.sabai-dee.com

Votes

Translate

Translate

Report

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
Guest
Mar 25, 2008 Mar 25, 2008

Copy link to clipboard

Copied

LATEST
Thanks for the info Azadi, been having the same problem and looking everywhere for the answer.

Votes

Translate

Translate

Report

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
Documentation