I'm using Notepad++, and I know for sure that it works when linking different files to the main HTML file.Here is the HTML code I'm using:
<link rel="stylesheet" type="style/css" href="adventure.css"></link>
<script src="adventure.js"></script>
</head>
<body>
<button onclick=log("testing")>Click Me</button>
<div id="box">
<div id="out"></div>
</div>
</body>
And here is the JavaScript code:
function Gid(id) {
return getElementById(id);
}
function log(s) {
Gid("out").innerHTML = s + "<br>" +
Gid("out").innerHTML;
}
And the CSS for the divs
#box {
width:500px;
height:300px;
border:5px solid black;
overflow:auto;
}
#out {
width:500px;
}
Please help me figure out why it's not working.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…