Doesn't it need to be in a closure,

$(function () {
    setInterval(function() {
        $.post('/Sale/UpdatePrice', 
            {SaleId : @Model.Id},
            function(data){
                $('#mPrice').val(data);    
            }
        )}
    ,5000); //refresh every 5 seconds
});


jQuery: missing ] after element list
Maybe someone can help me with a small problem I'm having. I'm trying to use this: http://jquery.malsup.com/form/ to create a submit form for Wordpress. I've tested it on a regular site(not WP) and it works. I can't figure out why it won't work in wp.

This is my form. I've created two page templates, one has the form, the other has the wp_insert_post code. If I change the form action to action="http://mysite.com/page.php" it works, if I point it to a page template it doesn't. I need it to point to a page template for the wp_insert_post code to work. 

This is on one first page:

&lt;form id="myForm" action="http://mysite.com/submitest" method="post"&gt; 
Name: &lt;input type="text" name="name" /&gt; 
Comment: &lt;textarea name="comment"&gt;&lt;/textarea&gt; 
&lt;input type="submit" value="Submit Comment" /&gt; 




Thanks
