title: firing a event on text input in javascript
body: <pre><code>&lt;input type="text" class="form-control" id="sokeord" onkeyup="Validate(this)" 
  onvalidated="Ajax( 'GET', { view : '/search/all/', table : 'company', keyword : this.value } , Show, 'result')"&gt;
  </code></pre>
  
  <p>I have the above element on my page.</p>
  
  <p>The <code>onkeyup</code> event fires as expected and runs the function <code>Validate</code>. The function <code>Validate</code> (as you probably guessed) validates the input based on some parameters and, if the validation evaluates to <code>true</code>, <code>Validate</code> tries to fire the event <code>onvalidated</code> on the input element 'sokeord', but the <code>onvalidated</code> event does not fire. I have tried <code>$(element).trigger("onvalidated");</code></p>
  
  <p>Any idea what is wrong?</p>