Integrate virtual tour on website

I added <div> at the begining and </div> at the end with also <script>onload();</script> and removed <load> <script> and <style> tags. That includes deleting <!DOCTYPE html> , <html> , <head> , </head> , <body onload="onload()"> , </body> , </html> but it still don’t work…

Here is the link of the new code:

The added extra line is not working. I tried changing it to:
<script>window.onload = function(){onload();};</script>
but there is then too much recursion.

As there is so much JavaScript there, I am not prepared to try to debug further.

I modified the last line but nothing is displayed (there is no more “please waiting”). If you want to have a look to the script, here is the link of a .zip with some script and images: