cleaned up a lot of the code. preparing to build the preloaded next iframe