Calling a java-script function when the value of a Dojo auto-completer changes
posted 4 years ago
I am trying to have a java-script function executed when the value of a Dojo auto-completer is changed by the user.
But when I use the usual onChange event handler in the dojo auto-completer for executing java-scripts, it has no effect i.e. the java scripts are not called.
I have used the java scripts to do the following 2 things :
1) Call a struts 2 action (by notifying a topic and then listening it elsewhere).
2) Change the value of a hidden field (to pass on some data to the action).
Although for notifying a topic there is another way :
using attribute --> valueNotifyTopic="topicName".
This will publish the topic and I can listen it elsewhere to call an action.
But this method does not allow me to change the value of the hidden field I mentioned.
This is the code:
Here the onchange attribute seems to have no effect.