Jquery not displaying UL or LI tags in html -


i have simple code:

//preview copy it's being typed $('#copytext').keyup(function(e){     $('#copypreview').html($('#copytext').val()); }); 

when user enters html - can see preview of when save it.

however tags such <ul> , <li> not appearing. other html works such line breaks, bold, tables, styles... not lists (so far, see)  

you can assume it's not css, checked that.

sample text:

<b>all models ul recognized <br><b>important:</b> <br> <ul><li>adjustable range -73 316°c (-100 600°f)</li> <li>resolution sensitivity of -17.7°c</li> </ul>    

val() used

get current value of first element in set of matched elements

user html() instead

$('#copypreview').html($('#copytext').html()) 

Comments

Popular posts from this blog

jquery - How can I dynamically add a browser tab? -

node.js - Getting the socket id,user id pair of a logged in user(s) -

keyboard - C++ GetAsyncKeyState alternative -