Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Fix for OU sites that wrongly load empty frames with src="#", breaking frameset navigation in modern browsers.
// ==UserScript==
// @match*
// ==/UserScript==
if (top==window) {
var myframes = document.getElementsByTagName('frame');
for (var frame in myframes) {
if (!myframes.hasOwnProperty(frame) || typeof myframes[frame] == 'undefined' ) continue;
if (myframes[frame].src.match(/\/#$/)) myframes[frame].src="about:blank";
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.