Given the following HTML file,
<html>
<head>
<script>
function initialize() {
document.getElementById('id2')
}
</script>
</head>
<body>
<div id="id1">
<div id="id2"></div>
</div>
</body>
</html>
I would like to access the inner div tag using the
document.getElementById
function in the html header, which, although I read the contrary, does not seem to work (in Safari 6.0.5.), while it works to access the outer tag.