Javascript examples for jQuery Method and Property:append
Adding two tables dynamically
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <script type="text/javascript" src="https://code.jquery.com/jquery-1.7.1.js"></script> <style id="compiled-css" type="text/css"> table {// w w w . ja v a 2 s.co m display: inline-block; } </style> <script type="text/javascript"> $(window).load(function(){ var str = "<table><tr><td>Hello</td></tr></table>"; $('body').append(str+str); }); </script> </head> <body> </body> </html>