I was trying to set up a page on Google Sites to show of my work with some HTML canvas games I made. However, Google Sites' "Insert HTML" option is severely limited, it only lets you enter HTML code that has no external dependencies to work. As you can imagine, the kind of things I want to upload have textures, audio and multiple js files scattered throughout the code. All js files are referenced on the main HTML file, but this isn't working, it isn't picking up the other files and it's just showing a white screen.
Here is all of the HTML code (as you can imagine, 99% of the work is JS):
<html>
<div id="canvas_div_no_cursor">
<canvas id="gameCanvas" width="800"
height="600"></canvas>
</div>
<script type="text/javascript">
document.getElementById('canvas_div_no_cursor').style.cursor = "none";
</script>
<script src="js/classes.js"></script>
<script src="js/HUD.js"></script>
<script src="js/movement.js"></script>
<script src="js/gameplay.js"></script>
<script src="js/graphics.js"></script>
<script src="js/input.js"></script>
<script src="js/audio.js"></script>
<script src="js/Main.js"></script>
</html>
That's about it, all the rest of the code in in those referenced js files. Yes, I uploaded the whole folder to Drive, and even tried importing the html through there, it won't even let me. I searched online to no avail, does anyone have a clue to how I can do this? The only viable option I see is to transfer all the code from the files to the single HTMl file, but I don't even know if it would accept other calls such as .mp3 files and .png files.
You can upload the needed files to Google Drive and get a directo download link to them with this site. Once you have that, simply change the src
with the direct link and it should import it.