Changing DIV contents with innerhtml

The innerHTML property sets or returns the inner HTML of an element.

<html>
    <head>
        <script>
            function changeContent(){
                document.getElementById('customDiv').innerHTML = "Hello world";
            }
        </script>
    </head>
    <body onLoad="changeContent();">
        <div id="customDiv">
        </div>
    </body>
</html>