php jQuery with .change how can you automatically change the value
<p>I have this image and i like to work it out on jQuery now the image have a fixed size, but when I input on the <code>&lt;input type='text' name='img_logo' value='630px'&gt;</code></p>

<p>Like I put for example <code>530px</code> the image size should be change also.</p>

<p>Here's my code.</p>

<pre><code>&lt;form method='post'&gt;
    &lt;input type="text" name="logo_width" value="632px"&gt;
    &lt;p&gt;Format logo: &lt;span id="logo_size"&gt;632px&lt;/span&gt;&lt;/p&gt;
&lt;/form&gt;
</code></pre>

<p>the jQuery codes</p>

<pre><code>$(function(){
    $('input[name="logo_width"]').change(function(e) {
        var chk = $('input[name="logo_width"]').val();
        $('img#img_logo').attr(chk);
    });
});
</code></pre>

<p>and the image</p>

<pre><code>&lt;div class="logo"&gt;  
     &lt;img src="images/upload/' . $set_logo_img['filename'] . '"
         width="630px" align="center" id="img_logo" /&gt;
     &lt;br /&gt; 
&lt;/div&gt;
</code></pre>

<p>But when i do input some value on the <code>input='name=logo_width'</code> nothings change
is my code jQuery wrong?</p>
