Source Code: (back to article)
<!DOCTYPE html>
<html>
<body>
<p>Cliquez sur le bouton pour fusionner deux tableaux.</p>
<button onclick="myFunction()">Cliquez</button>
<p id="demo"></p>
<script>
function myFunction() {
var hege = ["Cecilie", "Lone"];
var stale = ["Emil", "Tobias", "Linus"];
var children = hege.concat(stale);
document.getElementById("demo").innerHTML = children;
}
</script>
</body>
</html>