Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Javascript > Ajax Toolbox - using onchange event

Reply
Thread Tools

Ajax Toolbox - using onchange event

 
 
itp
Guest
Posts: n/a
 
      10-23-2006
I have moved to Matt Kruse's Javascript Toolbox. It has some great
examples to get you going quickly!

Unfortunately all the examples are based on a form/submit model. I
would like to try using the onchange event ot submit a request. Has
anyone tried this and could maybe provide an example?

ref: http://www.ajaxtoolbox.com/about/

 
Reply With Quote
 
 
 
 
Matt Kruse
Guest
Posts: n/a
 
      10-23-2006
itp wrote:
> I would like to try using the onchange event ot submit a request. Has
> anyone tried this and could maybe provide an example?


What kind of example would you like?

Most of the examples aren't actually based on form submittal. They just use
form buttons to trigger code. You could trigger the same code via an
element's onchange event.

--
Matt Kruse
http://www.JavascriptToolbox.com
http://www.AjaxToolbox.com


 
Reply With Quote
 
 
 
 
itp
Guest
Posts: n/a
 
      10-23-2006
Hi Matt:

I would like to reproduce this page using your toolbox.
ref: http://tinyurl.com/n4pp2

I realize that the submit button only triggers a script, however the
<form action=program_name is used to determine what program to run. I
cannot figure out how to do this using an onchange.

By the way your stuff is great!!!

itp

Matt Kruse wrote:
> itp wrote:
> > I would like to try using the onchange event ot submit a request. Has
> > anyone tried this and could maybe provide an example?

>
> What kind of example would you like?
>
> Most of the examples aren't actually based on form submittal. They just use
> form buttons to trigger code. You could trigger the same code via an
> element's onchange event.
>
> --
> Matt Kruse
> http://www.JavascriptToolbox.com
> http://www.AjaxToolbox.com


 
Reply With Quote
 
itp
Guest
Posts: n/a
 
      11-26-2006
OK. I am making progress. I can now trigger the form from an onblur
event, however my XMLHttpRequest is showing up in a new browser
instance.

code extract..
------------------------------------------------------------------------------------------------------------
<form name="form2" action="/mycgilibp/AJAX43.pgm"
method="post" target="_blank" onSubmit="submitForm(this);return
false;">

<script type="text/javascript">

function submitForm(theform) {
var status = AjaxRequest.submit(theform,
//alert("hello");
{
'onSuccess':function(req){
document.forms['form2'].submitResults.value = req.responseText; }
}
);
return status;
}</script>

value1
<INPUT TYPE="text"
value="Tabbing out of this text box should trigger a submit and
display values below. "
NAME="value1" size="80"
maxlength="80"
target="_blank"
onBlur= "document.form2.submit()">
---------------------------------------------------------------------------------------------------------------------------------------

try it:
http://tinyurl.com/u3am7





itp wrote:
> Hi Matt:
>
> I would like to reproduce this page using your toolbox.
> ref: http://tinyurl.com/n4pp2
>
> I realize that the submit button only triggers a script, however the
> <form action=program_name is used to determine what program to run. I
> cannot figure out how to do this using an onchange.
>
> By the way your stuff is great!!!
>
> itp
>
> Matt Kruse wrote:
> > itp wrote:
> > > I would like to try using the onchange event ot submit a request. Has
> > > anyone tried this and could maybe provide an example?

> >
> > What kind of example would you like?
> >
> > Most of the examples aren't actually based on form submittal. They just use
> > form buttons to trigger code. You could trigger the same code via an
> > element's onchange event.
> >
> > --
> > Matt Kruse
> > http://www.JavascriptToolbox.com
> > http://www.AjaxToolbox.com


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to add onchange event to dropdown using xslt rekha XML 0 11-25-2008 10:03 AM
ASP.NET AJAX samples... I am looking for help with HoverMenu AJAX Toolbox control. JDeats ASP .Net 1 10-05-2007 07:50 PM
Ajax installed.. where are Ajax controls like popup in my VS toolbox ?? jobs ASP .Net 0 11-06-2006 01:23 AM
using the client side "onchange" event function Norm via DotNetMonster.com ASP .Net 3 06-15-2005 01:32 PM
IE Bug: onchange event not called when using <optgroup> in select drop-down Ryan McGeary Javascript 2 01-07-2004 01:03 AM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57