javascript - Show xml in TextArea using jQuery -


the following works in firefox , chrome, not in ie -

<html> <head> <title>test ie</title> <script src="http://code.jquery.com/jquery-latest.min.js" type="text/javascript"></script> </head> <body> <button onclick="ftest2()">test textarea</button> <br /> <textarea rows="4" cols="50"  id="log" >  textholder . . .  </textarea>  <script type="text/javascript" >  var currentline = 3; var strxml = "<xmlstring id='misssing' >" + currentline + "</xmlstring>";      function ftest2() {       $('#log').html(strxml);     }  </script>  </body> </html> 

found -

i had use

$('#log').val(strxml); 

instead of

$('#log').html(strxml); 

Comments

Popular posts from this blog

linux - xterm copying to CLIPBOARD using copy-selection causes automatic updating of CLIPBOARD upon mouse selection -

c++ - qgraphicsview horizontal scrolling always has a vertical delta -