jayapalchandran
06-19-2009, 11:47 PM
Hi,
how to insert elements inline using javascript at any place in a html document
look at the code so that you will understand my query.
<body>
<div> ... </div>
...
...
...
<script>
var tm = document.createElement("div")
tm.style.border = "1px solid gray"
tm.style.paddig = "5px"
tm.innerHTML = "testing"
document.write(tm)
</script>
...
...
...
</body>
the above javascript code will print HTMLDivElement or something similar to this...
how to insert elements inline using javascript at any place in a html document?
how to insert elements inline using javascript at any place in a html document
look at the code so that you will understand my query.
<body>
<div> ... </div>
...
...
...
<script>
var tm = document.createElement("div")
tm.style.border = "1px solid gray"
tm.style.paddig = "5px"
tm.innerHTML = "testing"
document.write(tm)
</script>
...
...
...
</body>
the above javascript code will print HTMLDivElement or something similar to this...
how to insert elements inline using javascript at any place in a html document?