|
-
March 31st, 2009, 02:35 PM
#1
Event (on)change issue
I am using prototype's framework.
I wish to fire it upon changed value in, eg: select element, if option changes.
Code:
Event.observe(document.body, 'change', function(event) {
alert('I AM EVENT');
});
Doesn't work in IE7, but does in all other browsers.
Why?
Ipsens
-
March 31st, 2009, 04:04 PM
#2
Re: Event (on)change issue
I'm not exactly sure as to why that won't work. I have had trouble in the past with document.body. Have you tried document.getElementsByTagName('body')[0] instead?
If the post was helpful...Rate it! Remember to use [code] or [php] tags.
-
March 31st, 2009, 04:48 PM
#3
Re: Event (on)change issue
Well, that doesn't work in IE7 as well
Ipsens
-
March 31st, 2009, 05:03 PM
#4
Re: Event (on)change issue
I would suggest you contact prototype then. It could be a bug.
If the post was helpful...Rate it! Remember to use [code] or [php] tags.
-
March 31st, 2009, 05:08 PM
#5
Re: Event (on)change issue
Ipsens
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|