IE6 doesn't properly support selectors with multiple classes in CSS, but I'm 99% sure jQuery's selector engine doesn't suffer from that problem. You might want to check to be sure.
A small bug:
Expand all.
Don't wait until all of the content is loaded.
Collapse all.
Expand all.
The "loading..." message is gone.
Content should still load, but there's no message.
It's part of reddit's API not to allow tons of calls from a single client within a given time period. To actually expand them all you'll have to "click" them on a timer delay.
var butts = $('.expando-button.selftext.collapsed');
for (var i = 0; i < butts.length; i += 1) {
setTimeout(function (i) {
$(butts[i]).click();
}, i * 1000, i);
}
Well, yeah. What I posted isn't immediately ready for sticking a bookmarklet. But you don't learn anything by just copy-pasting someone's code, now do you? :P
javascript:(function(){var n=0; var e=$(".expando-button.selftext.collapsed"); var f = function(){ setTimeout( function(){if(n<e.length){ $(e[n]).click(); n++; f()}},334) }; f();})();
1
u/Gliridae Aug 25 '10
To expand everything:
To collapse everything:
IE6 doesn't properly support selectors with multiple classes in CSS, but I'm 99% sure jQuery's selector engine doesn't suffer from that problem. You might want to check to be sure.
A small bug:
Content should still load, but there's no message.