The brute-force way to do it is to run a proxy on your own server that loads the page in question, strips out either some or all of the javascript, then serves it onward.
Replacing 'top.location' with 'self.location' probably does the trick for 95% of sites.