Reputation: 4485
hey guys I have just try to implement my change event in coffeescript but its not working. Will any help me
$('#subscription_id").on "change", ->
console.log "Hello"
outputs = $(this).val()
if outputs
$('#subscription_id').prop "disable", "false"
else
$('##subscription_id').prop "disable", "true"
Upvotes: 1
Views: 6974
Reputation: 6946
The colors indicate the problem :
$('#subscription_id").on "change"
Should probably be
$('#subscription_id').on "change"
Upvotes: 11