// ==UserScript==
// @name           Fix New Facebook
// @namespace      http://artzilla.org/
// @include        http://www.facebook.com/home.php
// @description    Swap columns, hide ads, and fix tiny fonts in the new Facebook design (July 2008) 
// @author         Jamie Wilkinson <jamie@internetfamo.us>
// ==/UserScript==

// from diveintogreasemonkey.com, thanks
function addGlobalStyle(css) {
    var head, style;
    head = document.getElementsByTagName('head')[0];
    if (!head) { return; }
    style = document.createElement('style');
    style.type = 'text/css';
    style.innerHTML = css;
    head.appendChild(style);
}

// the magic
addGlobalStyle(

  // swap home screen columns
  '.UITwoColumnLayout_NarrowContent { float: left !important; }'
  +'.UITwoColumnLayout_Content { float: right !important; }'

  // fix the menubar's tiny font size per Greg, http://halvfet.com
  +"#dropmenu_container div, #fb_menubar { font-size: 12px; }"

  // and remove "social ads" in newsfeeds, sidebar "sponsors", and the entire ad column
  +".social_ad, .sponsor, #home_sponsor, .adcolumn { display: none !important; }"

);

TODO: need to allow .js file uploads so we can upload userscripts!