Javascript examples for jQuery:Select Dropdown
Add "<li>" into "<ul>" using jquery
<html> <head></head> <body> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script> <div id="mycontainer"> My Div//from w ww. j a va 2 s .c o m </div> <script> var myhtml = "<div><ul></ul></div>"; var msg = "<li>some message</li>"; $(mycontainer).append($(myhtml).find("ul").append(msg)) </script> </body> </html>