Hey james, thanks for the help but using your code when i submit the
checkbox and text appears and immediatly dissapears again ...

On 20 mrt, 22:32, James <james.gp....@gmail.com> wrote:
> Sorry, I meant "bind submit to form", not checkbox.
>
> Your code would be more something like:
>
> $(document).ready(function(){
>
>      $("form#chatform").submit(function(){
>           $test = '<input name="test" type="checkbox" value="1">';
>           $("#messagewindow").prepend($test+"<b>"+$("#msg").val()+"</
> b><br />");
>
>           $test.click(function() {
>                alert('test');
>           });
>           return false;
>      });
>
> });
>

Reply via email to