[QUOTE=helto]I have extra code that references the parent when loading games in an iframe.
passing/referencing dynamic data[/QUOTE]
Are those things stuff you use/need in your game ?
If so, I guess you could use AJAX for passing/referencing and "parent" (?).
As for adding JS functions, use those functions in a plugin
If those are irrelevant to the game itself, simply don't copy the index.html when copying your files to the destination site, rather using the HTML entry point file in there.
It is still not clear to me what you're doing exactly and why you need editing of the file. It sounds even like you shouldn't be editing it at all.