writing text field values to the document in javascript
<pre><code> function submitValue () {
        var content = $('input[name="foo"]').val();
        $('.teamcolumn').html(content); 

    }


$('#team').submit(submitValue());
</code></pre>

<p>I have also tried this to submit the button, but neither have worked.</p>

<pre><code>$('#team').submit(function() {
    $(this).val()).appendTo('.teamcolumn');
});
</code></pre>

<p>html: </p>

<pre><code>&lt;form&gt;
      &lt;input name="foo" id="team" class="inputright" type="text" value="Team?"&gt;
                &lt;input type="submit" value= "Go"&gt;
    &lt;/form&gt;

&lt;div class="teamcolumn TOSRcolumn"&gt;&lt;/div&gt;
</code></pre>

<p>I want to write the value given to me in the text field to the div with the class .wincolumn when a user clicks the submit button. Been playing around with a bunch of different methods but can't seem to figure it out</p>

<p>UPDATED CODE:</p>

<pre><code>&lt;html&gt;
&lt;head&gt;
&lt;script src="jquery.js"&gt;&lt;/script&gt;
&lt;script&gt;
$("input[type='submit']").click(function(e) {
    e.preventDefault();
    var value = $(.input[name="foo"]).val();
    $('.teamcolumn').html(value);
    return false;

});


&lt;/script&gt;
&lt;/head&gt;
&lt;body&gt;
&lt;form&gt;
&lt;input name="foo" id="team" class="inputright" type="text" value="Team?"&gt;&lt;/input&gt;
&lt;input type="submit" value"Go"&gt;&lt;/input
&lt;/form&gt;
&lt;/body
&lt;/html&gt;
</code></pre>
