Skip to content

Instantly share code, notes, and snippets.

@humantorch
Created August 18, 2009 09:47
Show Gist options
  • Save humantorch/169650 to your computer and use it in GitHub Desktop.
Save humantorch/169650 to your computer and use it in GitHub Desktop.
// ==UserScript==
// @name yh fixed nav
// @namespace http://userstyles.org
// @description Sets the YH! navigation as a fixed div.
// @author berge
// @homepage http://userstyles.org/styles/14283
// @include http://yayhooray.com/*
// @include https://yayhooray.com/*
// @include http://*.yayhooray.com/*
// @include https://*.yayhooray.com/*
// ==/UserScript==
(function() {
var css = "@namespace url(http://www.w3.org/1999/xhtml); #navigation {background: white; position:fixed !important;}";
if (typeof GM_addStyle != "undefined") {
GM_addStyle(css);
} else if (typeof addStyle != "undefined") {
addStyle(css);
} else {
var heads = document.getElementsByTagName("head");
if (heads.length > 0) {
var node = document.createElement("style");
node.type = "text/css";
node.appendChild(document.createTextNode(css));
heads[0].appendChild(node);
}
}
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment