How would I create a void element?


#1

How do I create a void element(an element without a closing tag) with jQuery? Is there a special function or technique I need to know about?

Thanks in advance!


#2

What is wrong with:

$(document).ready(function(){
    $('#one').after('<hr>');    

})

Is this not what you want?


#3

How would I create one with text, like the < input > tag?


#4
$('#one').after('<input id="name" name="name" value="text">');

#5

Oh, okay.
Thank you!