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

Populate a select Box without reloading Page

Explorer ,
Jan 27, 2009 Jan 27, 2009
I have about three to four select boxes (dropdowns), that I want to populate the next select drop down based on user selection from the previous select dropdown and vise versa without having a page reload. This is an app we are migrating from flash to CF because of too much problem with flash.
Please can you show examples of doing this
2.0K
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
LEGEND ,
Jan 27, 2009 Jan 27, 2009
google "coldfusion related selects" or "coldfusion chained selects"

Azadi Saryev
Sabai-dee.com
http://www.sabai-dee.com/
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
Explorer ,
Jan 28, 2009 Jan 28, 2009
Thanks Azadi, It looks like this method is only for Select dropdown options Only. The page I am working on has textboxes also that has to be refreshed with data when the selection from the the final select drop down is selected.

Is there a way I can get this done without reloading or refreshing the page? I mean refresh data in the Select Drop down and textboxes?

Thanks
E
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
LEGEND ,
Jan 28, 2009 Jan 28, 2009
eziokolo wrote:
>
> Is there a way I can get this done without reloading or refreshing the page? I
> mean refresh data in the Select Drop down and textboxes?
>
> Thanks
> E
>

Yes, but you must first answer yourself, "Where does the data come from."

From a user interface point of view you simply use JavaScript to access
the various form control DOM elements and change their values on the
desired events.

But you have to know where the data can come from. To do it without a
refresh, the client has to already have to data. If there is too much
data do deliver all at once to the client, then you can *not* do it
without some type of request to the server.

But you can make such a request without refreshing the user interface by
accessing it with other technologies such as asynchronous JavaScript and
XML, popularly known as AJAX.

Or you could go to a more advanced client interface then the HTTP
browser. Adobes preferred tool is Flex, but that gets you back to
Flash, and I do not know why you are trying to get away from Flash so
that may not be that appealing to you.
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
New Here ,
Jan 28, 2009 Jan 28, 2009
Hi eziokolo,

You have to use AJAX to populate the data from the database

If you are using the hardcoded value then you have to use simple javascript
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
Explorer ,
Jan 29, 2009 Jan 29, 2009
This is really not working for me. I have been able to use AJAX to populate the Select Dropdown Options. The problem I am having now is to, based on the Last of the Four Dropdown Seect options. To capture the selected value and pass that as an argument to a CFC to return a query that I will use to pupulate other Text Boxes also a Table or a Grid.

PS Help please needed with examples.

Thanks
E
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
LEGEND ,
Jan 29, 2009 Jan 29, 2009
quote:

Originally posted by: eziokolo
This is really not working for me. I have been able to use AJAX to populate the Select Dropdown Options. The problem I am having now is to, based on the Last of the Four Dropdown Seect options. To capture the selected value and pass that as an argument to a CFC to return a query that I will use to pupulate other Text Boxes also a Table or a Grid.

PS Help please needed with examples.

Thanks
E

One step at a time. Are you able to capture value?

Also, forget about grids. They are either applets or movies, neither of which plays with javascript.
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
Explorer ,
Jan 29, 2009 Jan 29, 2009
Yes I am able to capture values for dropdown #1 but Dropdowns #2 is throwing an error when I select from dropdown 1



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
Explorer ,
Feb 02, 2009 Feb 02, 2009
LATEST
The Bind to all the cfselects are working properly. Now how can I popluate input fields in a table row format with the query data from the last selection from the cfselect?
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