kmunky
kmunky

Reputation: 15593

jquery append to window

how can i append a div directly to the window object?

<html>
<head>
</head>
      <body>
           <div><div>
           <ul>..</ul>
      </body>
</html>

and i want to append an element after the ul, but not something like $('ul').after(element), i just want to append it directly to body. thanks

Upvotes: 7

Views: 9160

Answers (1)

Sampson
Sampson

Reputation: 268424

$("body").append(element); or $(element).appendTo("body");

Upvotes: 8

Related Questions