jQuery $.post basics
<p>I'm just learning how to use jquery, and I'm beyond confused. Here's what I'm trying to do (for practice/learning purposes):</p>

<ol>
<li>Take an input</li>
<li>Post the input into a div tag using jquery</li>
</ol>

<p>Here's my code.. but it's not working</p>

<pre><code>&lt;script type="text/javascript"&gt;
function test(data) {
$.post("&lt;?php echo $_SERVER['PHP_SELF']; ?&gt;", function(data) {
    $("#lol").innerHTML = data;
});
}
&lt;/script&gt;

&lt;form action="" onsubmit="test($(this.children()))" method="POST"&gt;
&lt;input type="hidden"
    value="derp" /&gt;
&lt;input type="text"
    name="herp" /&gt;
&lt;a href="javascript:void(0)"
    onclick="test($(this).parent())"&gt;
    Submit
&lt;/a&gt;
&lt;/form&gt;
&lt;div id="lol"&gt;...&lt;/div&gt;
</code></pre>

<p>Some help/tutorial explanation would be absolutely wonderful. Thanks!</p>
