Is there any way we can get the HTML5 player, or specifically the AGKPlayer.js module to use the current web page path, instead of simply looking for AGKPlayer.data?
The reason I ask is that because I'm not a very good web developer, my website uses <base href='//localhost/website/' /> to ensure that 1) All webpages use the same basic folder structure no matter how many levels they are down, and 2) I don't have to redesign my whole website because I'm lazy.
Or, does anyone know the JS to get this info so I can update the file myself?
*****EDIT*****
Ok, the js I need is this...
var pathArray = window.location.href.split( '/' );
var newPathname = "";
for (i = 0; i < ( pathArray.length - 1 ); i++) {
newPathname += pathArray[i];
newPathname += "/";
}
I've updated the main html to point to the correct location,
(script.src = newPathname + "AGKPlayer.asm.js"; var memoryInitializer = newPathname + 'AGKPlayer.html.mem'; and script.src = newPathname + "AGKPlayer.js"; ) but adding this code into AGKPlayer.js to point to AGKPlayer.data still isn't working. (I now get error 'Uncaught Error: Not Found : http://localhost/teamdefiant/AGKPlayer.data' the new path should be 'http://localhost/teamdefiant/software/oot/AGKPlayer.data') Infact, adding a window.alert into AGKPlayer.js doesn't pop up an alert?!?!
HELPS!