I'm trying to dynamically add an input box element directly after an input checkbox, onclick of that checkbox. I am able to create the input box dynamically but since the checkbox I'm trying to add after is not a parent I can't append a child to it. How can I get around this? Which function do I use?

Thanks