tratiecauseds
New Member
I am using JQUery and trying to create a panel for my HTML page.The panel contains mutiple divs. My JavaScript function is:\[code\]function createQuestionPanel() { var topDiv = $('<div>top div</div>'); var questionDiv = $('<div>bottom div</div>'); topDiv.after(questionDiv); return topDiv;}\[/code\]I call this function and append it to another JQuery representation of a HTML element. The problem is it only displays the topdiv. I want it to display both the bottom and top div. Do I need to wrap all the divs in my createQuestionPanel() method or is there a better way to do this?Thanks.