Thread
:
How not to add multiple listeners
View Single Post
02-02-2013, 10:47 PM
PM User
|
#
4
felgall
Master Coder
Join Date: Sep 2005
Location: Sydney, Australia
Posts: 5,455
Thanks: 0
Thanked 498 Times in 490 Posts
Another alternative would be to have the event listener remove itself again when it runs - that way it can only run once for each time it is added.
__________________
Stephen
Learn Modern JavaScript -
http://javascriptexample.net/
Helping others to solve their computer problem at
http://www.felgall.com/
felgall
View Public Profile
Visit felgall's homepage!
Find More Posts by felgall