actually, the above code will not work.
func1() should be changed to:
function func1()
{
document.getElementById("newDiv1").innerHTML = "<scr"+"ipt>function func2(){alert('doesnt matter, any function will do');}</scr"+"ipt>";
document.getElementById("newDiv2").innerHTML = "<a...
basically, i need to do something like this:
<head>
<script>
function func1()
{
document.getElementById("newDiv1").innerHTML = "<script>function func2(){alert('doesnt matter, any function will do');}</script>";
document.getElementById("newDiv2").innerHTML = "<a...
i am having a similar problem, kinda tough to explain, but here it goes:
i have a page with notes listed on it. above the notes is an empty <div>, and each note is written in its own <div>. beside each note is a link to edit that note. clicking this will do two things: 1) change the note...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.