page to load in div tag

  • Thread starter Thread starter jessnair
  • Start date Start date
J

jessnair

Onclick of buttons i need the corresponding page to load in the
'content' div tag, for some reason the following is not
working..........?

function load(arg)
{
var url = arg + ".html";
document.getElementByID("content").src = url;
}

<div id="content">
</div>
 
Hello (e-mail address removed),

use innerHtml property
Onclick of buttons i need the corresponding page to load in the
'content' div tag, for some reason the following is not
working..........?

function load(arg)
{
var url = arg + ".html";
document.getElementByID("content").src = url;
}
<div id="content">
</div>
---
WBR,
Michael Nemtsev :: blog: http://spaces.msn.com/laflour

"At times one remains faithful to a cause only because its opponents do not
cease to be insipid." (c) Friedrich Nietzsche
 
Of course it's not working. What on earth possesed you to believe that
you could load a web page in a div tag?

Use an iframe tag.
 
Back
Top