title: Trigger a change based on the input that has been updated via another input field update
body: <p>I have an input field that can be updated by another input field, I'm trying to make a few things happen when this occurs, css changes and so on. I can't find a good way to trigger this.</p>
  
  <p>I've set up a jsfiddle with a simplified example.</p>
  
  <p>The idea is that when a field from form one is changed the alert is triggered on form 2.</p>
  
  <p><a href="http://jsfiddle.net/8KKHK/" rel="nofollow">http://jsfiddle.net/8KKHK/</a></p>
  
  <p><strong>HTML code :</strong></p>
  
  <pre><code>&lt;h3&gt;form 1&lt;/h3&gt;
  &lt;div id="form1"&gt;
    &lt;input type="text" data-pair="1"&gt;
    &lt;input type="text" data-pair="2"&gt;
    &lt;input type="text" data-pair="3"&gt;    
  &lt;/div&gt;&lt;!--#form1--&gt;
  
  &lt;h3&gt;form 2&lt;/h3&gt;
  &lt;div id="form2"&gt;
    &lt;input type="text" data-pair="1"&gt;
    &lt;input type="text" data-pair="2"&gt;
    &lt;input type="text" data-pair="3"&gt;    
  &lt;/div&gt;&lt;!--#form1--&gt;
  </code></pre>
  
  <p><strong>Javascript code :</strong></p>
  
  <pre><code>jQuery('input').bind("change keyup input",function(){
      var d = jQuery(this).attr("data-pair");
      var value = jQuery(this).val();
      jQuery('input[data-pair="'+d+'"]').val(value);
  });
  
  jQuery('#form2 input').change("change keyup input",function(){
      var d = jQuery(this).attr("data-pair");
      alert(d);           
  });
  </code></pre>