HTML5: The body element is optional

You can omit the <body> and even the <html> element itself in HTML5. However if you want to use <body>'s onload event, you can replace it by window's onload event and assign the JavaScript function you want to call (when the document is loaded) as stated below: 

window.onload = function() { /* anonymous function directives */ };


Popular posts from this blog

Tuning ext4 for performance with emphasis on SSD usage

NetBeans 6.1: Working with Google´s Android SDK, Groovy and Grails