Dynamic onchange with Jquery
<p>I am attempting to use jQuery to dynamically populate the onChange attribute in a text field to run multiple functions. However i get an error in the console stating</p>

<pre><code>TypeError: required is not a function
</code></pre>

<p>When i type into the console required('test'); the function exists and returns true.</p>

<p>HTML</p>

<pre><code>  &lt;input id="test"&gt;
</code></pre>

<p>jQuery  </p>

<pre><code>var list_of_functions = get_validation(); //this returns a string "required('test'); valid('test');"  
$('#test').attr('onChange', list_of_functions);
</code></pre>

<p>Then when i go and change the fieldtext, I get an error that the function doesnt exist. Any help? Thanks.</p>
