Monday, May 20, 2024
 Popular · Latest · Hot · Upcoming
106
rated 0 times [  107] [ 1]  / answers: 1 / hits: 18766  / 13 Years ago, wed, july 13, 2011, 12:00:00

How do I trigger a change event on textbox in a backbone view?



I tried:



events: {
onChanged input.autocomplete: update
}


update didn't get fired. I also tried change.



What is the name of the event for textchange?


More From » backbone.js

 Answers
8

This should work:



events: {
change input.autocomplete: update
}



  1. Is the selector (input.autocomplete) correct?

  2. Change fires on blur, not on keydown - does this agree with your requirement?


[#91215] Monday, July 11, 2011, 13 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
andrewb

Total Points: 259
Total Questions: 124
Total Answers: 90

Location: Ivory Coast
Member since Sun, Mar 7, 2021
3 Years ago
;