CodeCharge Studio
search Register Login  

Visual Web Reporting

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> Archive -> GotoCode Archive

 Submit without clicking button

Print topic Send  topic

Author Message
Karen
Posted: 02/24/2003, 10:24 PM

I would like to create a search form based on a drop-down list. Once the value is selected, is it possible to skip clicking on the submit button, i.e., select value = submit? Can anyone guide me how to do this? Thanx in advance.
Headhunter
Posted: 02/24/2003, 11:58 PM

Ad the following to the "select" tag in your html code:
onchange="document.forms[0].submit();"

Example:

<select class="TrackitStudioSelect" id="" tabindex="0" onchange="document.forms[0].submit();" name="hwr_category">

Greetings.

http://www.dbweaver.com
Karen
Posted: 02/25/2003, 11:18 PM

That's exactly what I want to do but how do I go abt applying it to a listbox on a search form in CC?


Something like this in the form footer?

<script language="Javascript">
document.Form.cat_id.onchange = submit();
</script>


Can anyone help me? Thanx.
Karen
Posted: 02/26/2003, 4:19 PM

I tried this...

<script language="Javascript">
document.Form.cat_id.onchange = document.forms[0].submit();
</script>


but it seems to detect a change in the listbox even before the page is displayed and submits it immediately so I never get a chance to display my search form. Perhaps I'm not putting it in the correct place. Where else can I place it? Or perhaps another condition to say that apply this only after the page has opened? Can anyone help me pls? I would appreciate any advice. Thanx very much.
lneisius
Posted: 02/26/2003, 6:27 PM

Check this out to see if it helps
http://codechargers.net/ccs/kb.php?event_id=59&category_id=40&language_id=1
Karen
Posted: 02/27/2003, 3:50 AM

I can get it to work if I manually edit the html, adding onchange to the select input. But is there a way to do this in CC so that I don't have to manually edit everytime I regenerate the page? Just being hopeful. Thanx.

   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

Internet Database

Visually create Web enabled database applications in minutes.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.