Ajax "onchange" won't fire untill after user clicks out of input box

ajax , php , onchange Reading, United Kingdom
  • 9 years ago

    I'm starting to learn ajax, and have hit a little bit of a stumbling block. What I am trying to do is enter some text in an input box, and have that update into a

    . It does work, however, it only updates when the user clicks out of the box. Ideally I would want to to update as soon as text is entered, or maybe after a few seconds delay. I had thought the "onchange" value would call the update as soon as it is changed, but it dosen't seem to work that way.

    Heres the code I'm using: Year.php [code]

  • 9 years ago

    Sorry about that, - posting again in more legible format.

    Heres the code I'm using: Year.php

Post a reply

Enter your message below

Sign in or Join us (it's free).

Contribute

Why not write for us? Or you could submit an event or a user group in your area. Alternatively just tell us what you think!

Our tools

We've got automatic conversion tools to convert C# to VB.NET, VB.NET to C#. Also you can compress javascript and compress css and generate sql connection strings.

“The trouble with programmers is that you can never tell what a programmer is doing until it's too late.” - Seymour Cray