473,395 Members | 1,763 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

text input onChange not firing

ms
I have come across a problem where if a user enters the same text into
a text input after the value has been programmatically changed, the
onChange event does not fire for the second change.

The following code demonstrates this:

<html>
<body>
<input type=text value='yyy' onchange="this.value='xxx'"></input>
<input type=text value='2'></input>
</body>
</html>
- Change the value of the first text box to (eg) 'aaa', and tab away.
'aaa' will change to 'xxx'.
- Tab back to the first text box, and again enter 'aaa'. Tab away and
the text stays as 'aaa'. The onChange event does not fire. This has
also been confirmed using .net studio to break into similar code.

Is this a known bug, and is there a work-around for it?

Thanks

MS
Jul 23 '05 #1
4 31022
ms wrote:
I have come across a problem where if a user enters the same text into
a text input after the value has been programmatically changed, the
onChange event does not fire for the second change.
Which browser? Worked every time for me in Safari 1.0.3, Firefox 1.0
and IE 5.2 on Mac.

Perhaps you mean some version of IE on some version of Windows?

[...] Is this a known bug, and is there a work-around for it?


Use a real browser? ;-)

--
Fred
Jul 23 '05 #2

Fred Oz wrote:
ms wrote:
I have come across a problem where if a user enters the same text into a text input after the value has been programmatically changed, the
onChange event does not fire for the second change.
Which browser? Worked every time for me in Safari 1.0.3, Firefox

1.0 and IE 5.2 on Mac.

Perhaps you mean some version of IE on some version of Windows?

[...]
Is this a known bug, and is there a work-around for it?


Use a real browser? ;-)

--
Fred


Jul 23 '05 #3
IE 6 on XP Pro SP1

Jul 23 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Ron Brennan | last post by:
I've spent all morning on this and now think there is a (slight?) possiblity that onchange doesn't work for input type="file". Can anybody shed any light on this. The onblur fires just fine. The...
11
by: Randell D. | last post by:
Folks, I have seven text boxes which will contain measurements - I would like the user to input their values in the order that I have listed the boxes. How can I therefore make an input...
7
by: juglesh | last post by:
Hello, I would like to be able to have the user sort a list of items similarly to the way you sort your queue on Netflix.com. (the numbers dont change dynamically on netflix, they must be doing...
4
by: mflll | last post by:
I am looking into the different techniques of handling arrays of edit boxes in Java Script. The first program below works fine. However, are there better ways of doing this, where the person...
1
by: julian.tklim | last post by:
Hi, I've got an input box with popup calendar (date picker) all generated using javascipt. Once a date is selected from the datepicker window, the date value is populated back to the input...
18
by: Diogenes | last post by:
Hi All; I, like others, have been frustrated with designing forms that look and flow the same in both IE and Firefox. They simply did not scale the same. I have discovered, to my chagrin,...
7
by: Tim Slattery | last post by:
I'm trying to handle the onChange event in an <input type="file"> element. In IE, there's no problem: the event fires when a file in the "open" box is doubleclicked, or the "Open" button in the box...
7
by: kirkgilbert | last post by:
I am trying to do an onchange event in a form using a text field. The form is tied to a record set that is part of a repeated region. One the first record when I edit the data it works perfectly. ...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.