i'm not trying to run it onload.
i'm trying to create the method in the window object.
so i should be able to run the method by just typing slideSwitch() in the console.
but i wan it enclosed in the self executing function and only expose the method to the window object at the end.
edit: hmm...i'd found the anwser. http://pastebin.com/3CMsCkSK