I need some help. I am trying to insert an html tag inside a form using Jquery .append() inside $(document).ready().
This is what i have tested and not working:
Jquery part:
$(document).ready(function(){
$(".inner").append('<input type="checkbox" class="checkboxall">');
});
HTML part:
<form class="inner" action="" method="post">
</form>
What am I doing wrong?
Thank you in advance.
LE: i have analyzed the code in firebug and i notice that the form looks something like this: https://i.stack.imgur.com/jEVuA.png. What is the color of the form shaded?
LE: take care of the html validation part, very important, for me didn’t work because the html code was invalid in the document where i implemented this POC. (See picture above)
You are not doing something wrong.
I have just copy / paste your code and it is working : http://jsfiddle.net/gA9ry/