Javascript examples for Browser Object Model:Window Load
Handle DOMContentLoaded on window
<!doctype html> <html lang="en-US"> <head></head> <body> <object data="http://your server.svg" type="image/svg+xml" id="obj"></object> <script type="text/javascript"> window.addEventListener('DOMContentLoaded', function() { var obj = document.getElementById('obj'); obj.addEventListener('load', function(){ console.log('loaded'); });//from w w w . j a va 2 s. c om }); </script> </body> </html>