<!DOCTYPE html>
<html>
<head>
<script type='text/javascript'>
window.onload=function(){
var answer = [
"answer1",
"answer2",
"answer3",
"answer4"
];
document.getElementById("knap").onclick = function(){
var panel = document.getElementById("answer");
panel.innerHTML = answer[1];
}
}
</script>
</head>
<body>
<a id="knap" href="#">KNAP</a>
<p id="answer"></p>
</body>
</html>