html - Setting Value of Output Element via JavaScript in Edge and IE -


i have output tag value set dynamically via javascript. works fine in chrome , firefox, microsoft browsers (ie , edge) don't seem recognize it, , value empty these tags.

html:

    document.getelementbyid("owned").value = "test 1";          document.getelementbyid("used").value = "test 2";
    <output class="output" id="owned"></output>      <output class="output" id="used"></output>

it works when run code snippet on stack overflow.

question: there reason why values aren't being set on these browsers? there file must import html work on ie/edge?

use span , .innerhtml. <output> html tag seems not work on edge.


Comments