• Log InLog In
  • Register
Liquid`
Team Liquid Liquipedia
EDT 23:33
CEST 05:33
KST 12:33
  • Home
  • Forum
  • Calendar
  • Streams
  • Liquipedia
  • Features
  • Store
  • EPT
  • TL+
  • StarCraft 2
  • Brood War
  • Smash
  • Heroes
  • Counter-Strike
  • Overwatch
  • Liquibet
  • Fantasy StarCraft
  • TLPD
  • StarCraft 2
  • Brood War
  • Blogs
Forum Sidebar
Events/Features
News
Featured News
HomeStory Cup 27 - Info & Preview18Classic wins Code S Season 2 (2025)16Code S RO4 & Finals Preview: herO, Rogue, Classic, GuMiho0TL Team Map Contest #5: Presented by Monster Energy6Code S RO8 Preview: herO, Zoun, Bunny, Classic7
Community News
Weekly Cups (June 23-29): Reynor in world title form?12FEL Cracov 2025 (July 27) - $8000 live event16Esports World Cup 2025 - Final Player Roster14Weekly Cups (June 16-22): Clem strikes back1Weekly Cups (June 9-15): herO doubles on GSL week4
StarCraft 2
General
Weekly Cups (June 23-29): Reynor in world title form? StarCraft Mass Recall: SC1 campaigns on SC2 thread The SCII GOAT: A statistical Evaluation How does the number of casters affect your enjoyment of esports? Esports World Cup 2025 - Final Player Roster
Tourneys
FEL Cracov 2025 (July 27) - $8000 live event HomeStory Cup 27 (June 27-29) WardiTV Mondays SOOPer7s Showmatches 2025 $200 Biweekly - StarCraft Evolution League #1
Strategy
How did i lose this ZvP, whats the proper response Simple Questions Simple Answers [G] Darkgrid Layout
Custom Maps
[UMS] Zillion Zerglings
External Content
Mutation # 480 Moths to the Flame Mutation # 479 Worn Out Welcome Mutation # 478 Instant Karma Mutation # 477 Slow and Steady
Brood War
General
Flash Announces Retirement From ASL BW General Discussion ASL20 Preliminary Maps BGH Auto Balance -> http://bghmmr.eu/ StarCraft & BroodWar Campaign Speedrun Quest
Tourneys
[Megathread] Daily Proleagues [BSL20] GosuLeague RO16 - Tue & Wed 20:00+CET The Casual Games of the Week Thread [BSL20] ProLeague LB Final - Saturday 20:00 CET
Strategy
Simple Questions, Simple Answers I am doing this better than progamers do.
Other Games
General Games
Stormgate/Frost Giant Megathread Nintendo Switch Thread Path of Exile What do you want from future RTS games? Beyond All Reason
Dota 2
Official 'what is Dota anymore' discussion
League of Legends
Heroes of the Storm
Simple Questions, Simple Answers Heroes of the Storm 2.0
Hearthstone
Heroes of StarCraft mini-set
TL Mafia
TL Mafia Community Thread Vanilla Mini Mafia
Community
General
Trading/Investing Thread US Politics Mega-thread Things Aren’t Peaceful in Palestine Stop Killing Games - European Citizens Initiative Russo-Ukrainian War Thread
Fan Clubs
SKT1 Classic Fan Club! Maru Fan Club
Media & Entertainment
Anime Discussion Thread [Manga] One Piece [\m/] Heavy Metal Thread Korean Music Discussion
Sports
2024 - 2025 Football Thread NBA General Discussion Formula 1 Discussion TeamLiquid Health and Fitness Initiative For 2023 NHL Playoffs 2024
World Cup 2022
Tech Support
Computer Build, Upgrade & Buying Resource Thread
TL Community
The Automated Ban List
Blogs
from making sc maps to makin…
Husyelt
Blog #2
tankgirl
Game Sound vs. Music: The Im…
TrAiDoS
StarCraft improvement
iopq
Heero Yuy & the Tax…
KrillinFromwales
Trip to the Zoo
micronesia
Customize Sidebar...

Website Feedback

Closed Threads



Active: 550 users

TL BW Userscript

Forum Index > BW General
Post a Reply
Normal
b0lt
Profile Joined March 2009
United States790 Posts
Last Edited: 2011-09-12 07:14:16
August 24 2011 12:05 GMT
#1
Current version: 2.7a - Updated for modified format

I've been annoyed by having to scroll past the SC2 forums to get to the BW forums for a while now, and I have way too much time on my hands right now, so I polished up the two line script I posted in the power rank gone thread, and added a few other scripts.

They work with Chrome/Opera by default and Firefox with Greasemonkey installed, just download the script from herebelow, edit it if you want and install it (drag it into your browser window for Chrome/Firefox, do this on Opera (rename the scripts from foo.user.js to just foo.js if you're using Opera)), and refresh TL.

[image loading]
The individual scripts are:

BW TLPD
Changes the TLPD search bar to search the Brood War (KR) TLPD

Remove SC2 Elo Ranks
Removes the SC2 Elo ranks from below the liquipedia section on teamliquid.net

Featured Streams
Changes stream sidebar to only feature BW streams on teamliquid.net

BW Liquipedia
Changes the liquipedia search bar to search the Brood War liquipedia

Rearrange Forums
Rearranges the sidebar forum list to make teamliquid useful for Brood War fans (also scrapes for Power Rank)

I've got a git repo up at Google code if you want to use whatever I've hacked together to barely work.

Changelog:
2.7: Fixed bugs with power rank scraping
+ Show Spoiler +

2.6: Merged subsection stuff
Added power rank scraping to rearrange_forums

2.5: Split off each function into its own script, modified WhuazGoodJaggah's stream filter thing to move all the non-bw live streams into the non-featured section instead of removing them

2.4: Changed the link when clicking on the TLPD banner to go directly to the BW TLPD

2.3: Fixed the script run time to properly change everything before the page shows up on all 3 browsers

2.2: Swapped store and power rank links on the top bar
Moved around the order in which the default changes take place so more visibly obvious changes occur first (before the page fully loads)

2.1: Added all of teamliquid and blacklisted specific pages to run the script on, instead of whitelisting every individual page

2.0: Abstracted the section relocation stuff
Enderbantoo
Profile Blog Joined December 2009
United States465 Posts
August 24 2011 12:10 GMT
#2
Wow this is actually really cool. Thanks a ton, will be using this
At the biggest upset of all of bw, Shanghai SPL finals 2011
Sawamura
Profile Blog Joined August 2010
Malaysia7602 Posts
August 24 2011 12:13 GMT
#3
bless you my friend
BW/KT Forever R.I.P KT.Violet dearly missed ..
Elroi
Profile Joined August 2009
Sweden5595 Posts
August 24 2011 12:14 GMT
#4
This seems like a very good idea.
"To all eSports fans, I want to be remembered as a progamer who can make something out of nothing, and someone who always does his best. I think that is the right way of living, and I'm always doing my best to follow that." - Jaedong. /watch?v=jfghAzJqAp0
bITt.mAN
Profile Blog Joined March 2009
Switzerland3693 Posts
August 24 2011 12:18 GMT
#5
This is a better place to put it (:, I'm sure to use this, but please implement one more thing:

Have an option to filter out all SC2 streams, which can be ?toggled? so that the stream list is actually readable.
BW4LYF . . . . . . PM me, I LOVE PMs. . . . . . Long live "NaDa's Body" . . . . . . Fantasy | Bisu/Best | Jaedong . . . . .
BobTheBuilder1377
Profile Joined August 2011
Somalia335 Posts
August 24 2011 12:30 GMT
#6
Thank you sir! We appreciate your work.
kuroshiroi
Profile Joined November 2010
3149 Posts
August 24 2011 12:32 GMT
#7
I enhanced it for Opera, http://pastebin.com/7kdgzvms

Now it executes as soon as the html has been downloaded, instead of after everything (including pictures) has been downloaded. It makes it much more seamless but I think it only works on Opera right now.
Fly Jaedong, fly!
zatic
Profile Blog Joined September 2007
Zurich15325 Posts
August 24 2011 12:45 GMT
#8
Hey, good job! Do you want to make this configurable, so people can choose what to exclude? That would make it a great tool for everyone on this site!
ModeratorI know Teamliquid is known as a massive building
JustPassingBy
Profile Blog Joined January 2011
10776 Posts
August 24 2011 12:48 GMT
#9
Wow, that is quite nice, didn't even know that you could do this. :o
But can't you just collapse all sc2 forums, like you did with the general forum?
Black[CAT]
Profile Blog Joined July 2010
Malaysia2589 Posts
August 24 2011 12:49 GMT
#10
Erm, how to remove the script when I dont want it any longer? Never used greasemonkey before...
You mean ESPORTS isnt a synonym for SC2? ¯\_(ツ)_/¯ -Proud owner of a Filco Majestouch 2 with Cherry Blue Switches- BW or SC2? Why not both?
Sawamura
Profile Blog Joined August 2010
Malaysia7602 Posts
Last Edited: 2011-08-24 12:55:45
August 24 2011 12:53 GMT
#11
On August 24 2011 21:49 Black[CAT] wrote:
Erm, how to remove the script when I dont want it any longer? Never used greasemonkey before...


if you are using fire fox head on to add ons and click user script and than look on the right side it will say TL BW 2.0 and click remove it simple as 1,2,3 GG No Re.

by the way i would like to tinker around the script is there any word processor to open the script beside note pad ? It looks so clumsy and unfriendly in notepad plus I don't know what lines does what despite me having a programming background .
BW/KT Forever R.I.P KT.Violet dearly missed ..
b0lt
Profile Joined March 2009
United States790 Posts
August 24 2011 12:58 GMT
#12
On August 24 2011 21:32 kuroshiroi wrote:
I enhanced it for Opera, http://pastebin.com/7kdgzvms

Now it executes as soon as the html has been downloaded, instead of after everything (including pictures) has been downloaded. It makes it much more seamless but I think it only works on Opera right now.


Oh, I didn't realize it wasn't running until everything loaded. I merged your changes in and tested it with Chrome/Firefox/Opera and it worked on all 3, thanks for the tip
Also I missed some pages to whitelist (streams, some other page I forgot), so I just said fuck it and added all of www.teamliquid.net and blacklisted all of the exceptions I could find. Anyone who downloaded the script before reading this post should redownload and update to the newest version.

On August 24 2011 21:45 zatic wrote:
Hey, good job! Do you want to make this configurable, so people can choose what to exclude? That would make it a great tool for everyone on this site!


It's "configurable" right now by editing the main function in the script before installing it. It's pretty simple to make it do what you want. move_section(foo, bar) moves section foo to right above bar, remove_section(foo) removes section foo, and the stuff at the bottom can be commented out/uncommented to enable/disable. I'm literally brand new to userscripts, so adding configurability through a browser page or something would probably take me a bit (I'll probably get around to it eventually if no one else does, though.
b0lt
Profile Joined March 2009
United States790 Posts
Last Edited: 2011-08-24 13:04:39
August 24 2011 12:59 GMT
#13
On August 24 2011 21:48 JustPassingBy wrote:
Wow, that is quite nice, didn't even know that you could do this. :o
But can't you just collapse all sc2 forums, like you did with the general forum?

Well I actually read the sc2 forums, but less than the brood war forums, so collapsing/uncollapsing them over and over again would be worse than just scrolling past.

On August 24 2011 21:53 Sawamura wrote:
Show nested quote +
On August 24 2011 21:49 Black[CAT] wrote:
Erm, how to remove the script when I dont want it any longer? Never used greasemonkey before...


if you are using fire fox head on to add ons and click user script and than look on the right side it will say TL BW 2.0 and click remove it simple as 1,2,3 GG No Re.

by the way i would like to tinker around the script is there any word processor to open the script beside note pad ? It looks so clumsy and unfriendly in notepad plus I don't know what lines does what despite me having a programming background .


I use vim, but notepad2 is pretty good on windows. Also, the stuff you want to edit is right at the top of the file, in the middle to bottom of this function here:


function main() {
var news = new Section("nav_news_left_mid", 1, false);
var general = new Section("nav_general", 1, false);
var sc2 = new Section("nav_starcraft2", 1, false);
var bw = new Section("nav_broodwar", 1, false);
var games = new Section("nav_games", 1, false);
var blogs = new Section("nav_blogs", 1, false);
var replays = new Section("nav_replays", 1, false);

var calendar = new Section("nav_calendar", 2, true);
var streams = new Section("nav_streams", 1, true);
var tlpd = new Section("nav_tlpd", 1, true);
var liquipedia = new Section("nav_wiki", 1, true);
var tsl = new Section("nav_tslforum", 1, true);
var poll = new Section("nav_poll", 1, true);

/* Move the Brood War forums above the SC2 forums */
move_section(bw, sc2);

/* Move replays to above poll */
move_section(replays, poll);

/* Remove poll */
//remove_section(poll);

/* Move streams to above TSL */
move_section(streams, tsl);

/* Change liquipedia search to Brood War liquipedia */
for (var i = 0; i < document.forms.length; i++) {
var form = document.forms[i];
if (form.action == "http://wiki.teamliquid.net/starcraft2/index.php")
form.action = "http://wiki.teamliquid.net/starcraft/index.php";
}

/* Change default tlpd search to BW (Korea) */
document.forms.namedItem('frm_tlpd_search').elements.namedItem("type").children[3].selected = true;

/* Remove SC2 Elo rank display */
var rank1 = nextObject(document.forms.namedItem('frm_tlpd_search'));
var rank2 = nextObject(rank1);
rank1.parentNode.removeChild(rank1);
rank2.parentNode.removeChild(rank2);
}
OpticalShot
Profile Blog Joined October 2009
Canada6330 Posts
August 24 2011 13:11 GMT
#14
AWESOME
Just got it.
Bless you sir.
[TLMS] REBOOT
Sawamura
Profile Blog Joined August 2010
Malaysia7602 Posts
Last Edited: 2011-08-24 13:15:37
August 24 2011 13:13 GMT
#15
thanks bolt wordpad did the job .
BW/KT Forever R.I.P KT.Violet dearly missed ..
prosatan
Profile Joined September 2009
Romania7965 Posts
August 24 2011 13:15 GMT
#16
Thank you b0lt !
Happy Birthday Zatic !!
Lee JaeDong Fighting! The only church that illuminates is the one that burns.
Chef
Profile Blog Joined August 2005
10810 Posts
August 24 2011 13:16 GMT
#17
It's good to have SC2 in it's rightful place. Below Brood War
LEGEND!! LEGEND!!
mdb
Profile Blog Joined February 2003
Bulgaria4059 Posts
August 24 2011 13:20 GMT
#18
Thanks, absolutely amazing.
kuroshiroi
Profile Joined November 2010
3149 Posts
August 24 2011 13:20 GMT
#19
On August 24 2011 21:58 b0lt wrote:
Show nested quote +
On August 24 2011 21:32 kuroshiroi wrote:
I enhanced it for Opera, http://pastebin.com/7kdgzvms

Now it executes as soon as the html has been downloaded, instead of after everything (including pictures) has been downloaded. It makes it much more seamless but I think it only works on Opera right now.


Oh, I didn't realize it wasn't running until everything loaded. I merged your changes in and tested it with Chrome/Firefox/Opera and it worked on all 3, thanks for the tip
Also I missed some pages to whitelist (streams, some other page I forgot), so I just said fuck it and added all of www.teamliquid.net and blacklisted all of the exceptions I could find. Anyone who downloaded the script before reading this post should redownload and update to the newest version.
One thing though, the file needs to end in .js for it to work like that in Opera. i.e. the user. part needs to be removed. Otherwise it just works like normal, i.e. executing after everything has been loaded.

Nice job btw, I had a bunch of hacks for myself (like hiding the SC2 forum through CSS and changing the TLPD search to bw through a userscript) but you're a far better coder than I am
Fly Jaedong, fly!
Chef
Profile Blog Joined August 2005
10810 Posts
Last Edited: 2011-08-24 13:36:30
August 24 2011 13:23 GMT
#20
Is there a way to remove sections completely from the side bar, or just change the order? edit: nevermind I think you answered that.

"remove_section(sc2);" does not work T.T Guess I'll just move them for now

Is there any way you could make a script that removes SC2 events from the calendar :o It might be usable again!
LEGEND!! LEGEND!!
Yodo
Profile Joined March 2010
Russian Federation327 Posts
August 24 2011 13:40 GMT
#21
Can you add functionality to put all [BW] live-streams as featured (we have only few anyway) and all others as non-featured?
chaosTheory_14cc
Profile Blog Joined December 2010
Canada1270 Posts
August 24 2011 13:41 GMT
#22
Nice job. And yeah what Chef said, removal of all things SC2 from TL would greatly benefit those who don't use them. Especially the calendar
Sawamura
Profile Blog Joined August 2010
Malaysia7602 Posts
August 24 2011 13:44 GMT
#23
On August 24 2011 22:23 Chef wrote:
Is there a way to remove sections completely from the side bar, or just change the order? edit: nevermind I think you answered that.

"remove_section(sc2);" does not work T.T Guess I'll just move them for now

Is there any way you could make a script that removes SC2 events from the calendar :o It might be usable again!


That i can guarantee you will not be so easy lol
BW/KT Forever R.I.P KT.Violet dearly missed ..
chaosTheory_14cc
Profile Blog Joined December 2010
Canada1270 Posts
August 24 2011 13:45 GMT
#24
On August 24 2011 22:40 Yodo wrote:
Can you add functionality to put all [BW] live-streams as featured (we have only few anyway) and all others as non-featured?


Maybe not featured necessarily, but a way to simply separate all the BW streams from the mass of other SC2 streams would be amazing. I hate having to scroll through the non-featured looking for that little [BW] everytime there are no featured streams on.
Yodo
Profile Joined March 2010
Russian Federation327 Posts
August 24 2011 13:46 GMT
#25
Also we need script to return PR section back.
Chef
Profile Blog Joined August 2005
10810 Posts
August 24 2011 13:50 GMT
#26
On August 24 2011 22:44 Sawamura wrote:
Show nested quote +
On August 24 2011 22:23 Chef wrote:
Is there a way to remove sections completely from the side bar, or just change the order? edit: nevermind I think you answered that.

"remove_section(sc2);" does not work T.T Guess I'll just move them for now

Is there any way you could make a script that removes SC2 events from the calendar :o It might be usable again!


That i can guarantee you will not be so easy lol

A man can dream, can't he?
LEGEND!! LEGEND!!
Sawamura
Profile Blog Joined August 2010
Malaysia7602 Posts
August 24 2011 13:54 GMT
#27
On August 24 2011 22:50 Chef wrote:
Show nested quote +
On August 24 2011 22:44 Sawamura wrote:
On August 24 2011 22:23 Chef wrote:
Is there a way to remove sections completely from the side bar, or just change the order? edit: nevermind I think you answered that.

"remove_section(sc2);" does not work T.T Guess I'll just move them for now

Is there any way you could make a script that removes SC2 events from the calendar :o It might be usable again!


That i can guarantee you will not be so easy lol

A man can dream, can't he?


yes he can ^^
BW/KT Forever R.I.P KT.Violet dearly missed ..
Thratur
Profile Blog Joined June 2008
Canada917 Posts
August 24 2011 13:56 GMT
#28
Thank you so much.
letian
Profile Blog Joined May 2010
Germany4221 Posts
August 24 2011 13:57 GMT
#29
Oh, yesss
soujiro_
Profile Joined June 2010
Uruguay5195 Posts
August 24 2011 14:05 GMT
#30

Thanks a lot you are a true hero



On August 24 2011 22:40 Yodo wrote:
Can you add functionality to put all [BW] live-streams as featured (we have only few anyway) and all others as non-featured?


could you do this ?? that would be awesome =)
ace hwaiting!!
moktira *
Profile Blog Joined October 2010
Ireland1543 Posts
August 24 2011 14:19 GMT
#31
This is fantastic, thanks so much b0lt!
If in doubt, differentiate and set equal to zero
alffla
Profile Blog Joined November 2005
Hong Kong20321 Posts
August 24 2011 14:23 GMT
#32
this is awesomeee thanks so much
Graphicssavior[gm] : What is a “yawn” rape ;; Masumune - It was the year of the pig for those fucking defilers. Chill - A clinic you say? okum: SC without Korean yelling is like porn without sex. konamix: HAPPY BIRTHDAY MOMMY!
4vvhiplash7
Profile Joined December 2010
South Africa392 Posts
August 24 2011 14:34 GMT
#33
You are my new hero sir! I was feeling really depressed with our beloved bw for so many reasons at the moment and you just gave me a reason to be a proud bw fan once again. Thank you!
Cri du Chat
Profile Joined February 2010
Germany606 Posts
August 24 2011 14:35 GMT
#34
Very useful Thanks for the script.
WhuazGoodJaggah
Profile Blog Joined January 2009
Lesotho777 Posts
August 24 2011 14:38 GMT
#35
I thought about that just today, haha sooo nice. Thanks a lot man, I will alter it to my needs and install it on all my browsers.

@Chef
are you sure you did it right? What browser are you using? I removed the sc2 section and the news section without any problem. (maybe you need to uninstall the unaltered one before you install the new one)
small dicks have great firepower
Grobyc
Profile Blog Joined June 2008
Canada18410 Posts
August 24 2011 14:40 GMT
#36
Woah, this is crazy cool. Thanks b0lt
If you watch Godzilla backwards it's about a benevolent lizard who helps rebuild a city and then moonwalks into the ocean.
b0lt
Profile Joined March 2009
United States790 Posts
Last Edited: 2011-08-24 14:50:27
August 24 2011 14:44 GMT
#37
Just pushed another update to github, the script should run right after all the html is loaded on all 3 browsers now, so you shouldn't see items change and fly around during the page load. I'm going to move this to google code or something to make distribution of versions easier later, and I'll take a poke at the BW streams thing (it'd be a lot easier if each stream were wrapped in a span or something though, text parsing in javascript sucks). Sleep time now though

edit: Also yeah, removing the sc2 forums should work, you should probably make sure you do it after you move all the stuff though. Removing sc2 and then trying to move something above it or something probably results in Bad Things happening. Also make sure you're actually removing the script and installing it again if you're on chrome or firefox, when you install the script it makes a copy of it into your browser user profile.
LML
Profile Blog Joined March 2007
Germany1762 Posts
August 24 2011 14:46 GMT
#38
maybe you have to put the parameter as a string? as in remove_section('sc2'); ?
Unless he defined SC2 and such before, didn't look at the script.

I won't use it, it doesn't really bother me, as on the front page I just press the END button and then the PAGE UP button and am at the broodwar forums;)
LML
Sawamura
Profile Blog Joined August 2010
Malaysia7602 Posts
August 24 2011 14:52 GMT
#39
Bolt updated the monkey script it's now version 2.3 same installation method,download it from here https://github.com/jmgao/teamliquidbw/raw/master/tlbw.user.js thank you bolt ,now it immediately loads broodwar section first ! SO AWESOME !.
BW/KT Forever R.I.P KT.Violet dearly missed ..
Vibes
Profile Joined November 2008
Germany144 Posts
Last Edited: 2011-08-24 14:53:33
August 24 2011 14:53 GMT
#40
I really really want to thank you for this! :D

Hopefully there is a way to remove SC2 completely from TL - that would be perfect
Just another Jaedong fanboy <3
Sawamura
Profile Blog Joined August 2010
Malaysia7602 Posts
Last Edited: 2011-08-24 15:03:09
August 24 2011 14:59 GMT
#41
finally honour has been restored to tl.net T_T !!!!!!!!
BW/KT Forever R.I.P KT.Violet dearly missed ..
mustaju
Profile Blog Joined May 2010
Estonia4504 Posts
August 24 2011 15:02 GMT
#42
Downloaded it the moment I saw it. Big thanks!
WriterBrows somewhat high. https://www.youtube.com/watch?v=ndFysO2JunE
Wolf
Profile Blog Joined April 2010
Korea (South)3290 Posts
August 24 2011 15:03 GMT
#43
All it does for me is make TL load really slow.
Commentatorhttp://twitter.com/proxywolf
TL+ Member
Sawamura
Profile Blog Joined August 2010
Malaysia7602 Posts
Last Edited: 2011-08-24 15:08:56
August 24 2011 15:05 GMT
#44
Version 2.4 is already out head to the first page

and @wolf the script is doing fine for me no lags

 *  Changelog:
* 2.4: Changed the link when clicking on the TLPD banner to go directly to the BW TLPD
* 2.3: Fixed the script run time to properly change everything before the page shows up on all 3 browsers
* 2.2: Swapped store and power rank links on the top bar
* Moved around the order in which the default changes take place so more visibly obvious changes occur first (before the page fully loads)
* 2.1: Added all of teamliquid and blacklisted specific pages to run the script on, instead of whitelisting every individual page
* 2.0: Abstracted the section relocation stuff

BW/KT Forever R.I.P KT.Violet dearly missed ..
b0lt
Profile Joined March 2009
United States790 Posts
Last Edited: 2011-08-24 15:09:44
August 24 2011 15:08 GMT
#45
^ How are you posting this stuff before I do?

Fixed another annoyance that I've had, the big TLPD banner thing goes directly to the BW TLPD with the latest version.

On August 25 2011 00:03 Wolf wrote:
All it does for me is make TL load really slow.


What browser are you using? If it's firefox, what version of greasemonkey? The only thing I can think of that could cause that is if you already take forever to download the html, and your browser's engine can't do any predictive rendering because because the userscript has a hook on the document end.
soujiro_
Profile Joined June 2010
Uruguay5195 Posts
Last Edited: 2011-08-24 15:14:46
August 24 2011 15:09 GMT
#46
no lag here.

any chance you can set bw streams as featured or similar ??

edit***

another idea maybe taking out tsl button and new liquipedia
ace hwaiting!!
kuroshiroi
Profile Joined November 2010
3149 Posts
Last Edited: 2011-08-24 15:23:26
August 24 2011 15:19 GMT
#47
On August 25 2011 00:09 soujiro_ wrote:
another idea maybe taking out tsl button and new liquipedia

You can already do that by adding:
remove_section(tsl);
remove_section(liquipedia);

to the end of the main function. There's already a commented out remove_section(poll); in the code, just add some more stuff after that and make sure you put it in this order:
/* Move streams to above TSL */
move_section(streams, tsl);

/* Remove sections */
remove_section(tsl);
remove_section(liquipedia);

i.e. the remove_section calls should ideally be at the end of the main function.
Fly Jaedong, fly!
Chef
Profile Blog Joined August 2005
10810 Posts
August 24 2011 15:29 GMT
#48
Thank you so much :D Also remove section is working for me in the latest version.
LEGEND!! LEGEND!!
Count9
Profile Blog Joined May 2009
China10928 Posts
August 24 2011 15:32 GMT
#49
Awesome, plus source code makes it easy to configure with only function calls.
XsebT
Profile Blog Joined June 2009
Denmark2980 Posts
Last Edited: 2011-08-24 15:41:10
August 24 2011 15:40 GMT
#50
Hey, where did the replay section go? :S
Oh, there! :D

Thanks, this is great!
화이팅
Sawamura
Profile Blog Joined August 2010
Malaysia7602 Posts
Last Edited: 2011-08-24 15:42:56
August 24 2011 15:41 GMT
#51
On August 25 2011 00:40 XsebT wrote:
Hey, where did the replay section go? :S
Oh, there! :D

Thanks, this is great!


Ugh dude it's still there its's below tsl and by the way i didn't know i can customized tl.net so much lol lol XD

Edit : No more tsl,no poll i am such a happy bw fan now ;o
BW/KT Forever R.I.P KT.Violet dearly missed ..
Wohmfg
Profile Blog Joined January 2009
United Kingdom1292 Posts
August 24 2011 15:45 GMT
#52
Amazing! Thanks for this, works great.
BW4Life!
tyr
Profile Blog Joined February 2008
France1686 Posts
Last Edited: 2011-08-24 16:31:20
August 24 2011 16:22 GMT
#53
Why doesn't it work for me ?
I'm on Opera, I turned all the javascript options on, renamed it to tlbw.js in the right folder and it doesn't work.

edit : nvm, I made it work
"I'm always reminded of how manly Jaedong is every time I see him." -Bisu
corumjhaelen
Profile Blog Joined October 2009
France6884 Posts
August 24 2011 16:39 GMT
#54
Great ! Many thanks <3
‎numquam se plus agere quam nihil cum ageret, numquam minus solum esse quam cum solus esset
agarangu
Profile Blog Joined November 2010
Chile274 Posts
August 24 2011 17:02 GMT
#55
Thanks a lot! It's too awesome for me.
What's a quote anyway?
MrCon
Profile Blog Joined August 2010
France29748 Posts
August 24 2011 17:04 GMT
#56
Any way to make TLPDization the way I want ?
For instance when I TLPDize (T)NaDa, I would want it to do (T)NaDa by default. And same with maps, they're always TLPDized to international (ie : Terminus SE and I would want to make it Terminus SE )
That would be an huge time saver as when I make a LR thread I have to manually redo all the TLPD links.
WhuazGoodJaggah
Profile Blog Joined January 2009
Lesotho777 Posts
Last Edited: 2011-08-25 01:33:24
August 24 2011 17:27 GMT
#57
I added a function to remove all streams except bw streams.
let bw streams rule tl.net MUAHAHAHHAHAH
var let_bw_streams_rule_the_featured_list = function() {
var bwNodes = new Array();

// get all the bw streams
var featuredStreams = nextObject(document.getElementById("nav_streams"));
featuredStreams = nextObject(featuredStreams.firstChild).firstChild.firstChild;
for (var i=0; i < featuredStreams.childNodes.length; i++) {
var node = featuredStreams.childNodes[i];
if (node.nodeName == "A" && node.innerHTML.indexOf("[BW] ") != -1) {
bwNodes.push(node);
}
}

var moreStreams = document.getElementById("more_streams");
for (var i=0; i < moreStreams.childNodes.length; i++) {
var node = moreStreams.childNodes[i];
if (node.nodeName == "A" && node.innerHTML.indexOf("[BW] ") != -1) {
bwNodes.push(node);
}
}

// remove all the old featured streams
while (featuredStreams.hasChildNodes()) {
featuredStreams.removeChild(featuredStreams.firstChild);
}

// insert bw streams into the featured streams list
for (var i=0; i < bwNodes.length; i++) {
featuredStreams.appendChild(bwNodes[i]);
featuredStreams.appendChild(document.createElement("br"));
}
}


just insert the function somewhere between other functions (f.e. below move_section) and then call it where the other functions (like move_section) are called.

full script:
http://userscripts.org/scripts/show/111240
small dicks have great firepower
MrCon
Profile Blog Joined August 2010
France29748 Posts
August 24 2011 17:30 GMT
#58
Don't your script will include all streams that contain BW in their name (and perhaps "bw" too ?)
WhuazGoodJaggah
Profile Blog Joined January 2009
Lesotho777 Posts
August 24 2011 17:39 GMT
#59
On August 25 2011 02:30 MrCon wrote:
Don't your script will include all streams that contain BW in their name (and perhaps "bw" too ?)


it includes all streams that contain '[BW] ' in it which is unlikely to be in a username
small dicks have great firepower
MrCon
Profile Blog Joined August 2010
France29748 Posts
August 24 2011 17:40 GMT
#60
On August 25 2011 02:39 WhuazGoodJaggah wrote:
Show nested quote +
On August 25 2011 02:30 MrCon wrote:
Don't your script will include all streams that contain BW in their name (and perhaps "bw" too ?)


it includes all streams that contain '[BW] ' in it which is unlikely to be in a username

oops yeah I missed the [ ], embarrassing :p
Taekwon
Profile Joined May 2010
United States8155 Posts
August 24 2011 17:43 GMT
#61
You so beautiful
▲ ▲ ▲
prototype.
Profile Blog Joined July 2009
Canada4200 Posts
August 24 2011 18:17 GMT
#62
b0lt is my hero
( ・´ー・`)
Ideas
Profile Blog Joined April 2008
United States8087 Posts
August 24 2011 19:04 GMT
#63
this is the best thing ever lol

thankyou!
Free Palestine
fabiano
Profile Blog Joined August 2009
Brazil4644 Posts
August 24 2011 19:09 GMT
#64
this is amazing man!

its working flawlessly, thank you so much. SC2 stream flood was getting really annoying.
"When the geyser died, a probe came out" - SirJolt
Lebesgue
Profile Joined October 2008
4542 Posts
August 24 2011 19:17 GMT
#65
Amazing! Thanks a lot.
Yurie
Profile Blog Joined August 2010
11800 Posts
Last Edited: 2011-08-24 19:51:42
August 24 2011 19:51 GMT
#66
Just me using the following setup in this script?
+ Show Spoiler +
remove_section(sc2);
remove_section(replays);
remove_section(tsl);
move_section(games, bw);
move_section(news, blogs);
move_section(blogs, bw);


Thanks for making this, guess I'll go with a third party solution over the current site solution.
Cambium
Profile Blog Joined June 2004
United States16368 Posts
August 24 2011 20:05 GMT
#67
On August 25 2011 02:27 WhuazGoodJaggah wrote:
I added a function to remove all streams except bw streams.
let bw streams rule tl.net MUAHAHAHHAHAH
var let_bw_streams_rule_the_featured_list = function() {
var bwNodes = new Array();

// get all the bw streams
var featuredStreams = nextObject(document.getElementById("nav_streams"));
featuredStreams = nextObject(featuredStreams.firstChild).firstChild.firstChild;
for (var i=0; i < featuredStreams.childNodes.length; i++) {
var node = featuredStreams.childNodes[i];
if (node.nodeName == "A" && node.innerHTML.indexOf("[BW] ") != -1) {
bwNodes.push(node);
}
}

var moreStreams = document.getElementById("more_streams");
for (var i=0; i < moreStreams.childNodes.length; i++) {
var node = moreStreams.childNodes[i];
if (node.nodeName == "A" && node.innerHTML.indexOf("[BW] ") != -1) {
bwNodes.push(node);
}
}

// remove all the old featured streams
while (featuredStreams.hasChildNodes()) {
featuredStreams.removeChild(featuredStreams.firstChild);
}

// insert bw streams into the featured streams list
for (var i=0; i < bwNodes.length; i++) {
featuredStreams.appendChild(bwNodes[i]);
featuredStreams.appendChild(document.createElement("br"));
}
}


just insert the function somewhere between other functions (f.e. below move_section) and then call it where the other functions (like move_section) are called.

+ Show Spoiler [full script] +
// ==UserScript==
// @name TLBW
// @description Userscript to make teamliquid more useful for Brood War fans
// @version 2.4
// @include [url=http://teamliquid.net/*]http://teamliquid.net/*[/url]
// @include [url=http://www.teamliquid.net/*]http://www.teamliquid.net/*[/url]
// @exclude [url=http://teamliquid.net/sc2/*]http://teamliquid.net/sc2/*[/url]
// @exclude [url=http://teamliquid.net/store/*]http://teamliquid.net/store/*[/url]
// @exclude [url=http://teamliquid.net/tlfe/*]http://teamliquid.net/tlfe/*[/url]
// @exclude [url=http://teamliquid.net/tournaments/*]http://teamliquid.net/tournaments/*[/url]
// @exclude [url=http://teamliquid.net/vods/*]http://teamliquid.net/vods/*[/url]
// @exclude [url=http://www.teamliquid.net/sc2/*]http://www.teamliquid.net/sc2/*[/url]
// @exclude [url=http://www.teamliquid.net/store/*]http://www.teamliquid.net/store/*[/url]
// @exclude [url=http://www.teamliquid.net/tlfe/*]http://www.teamliquid.net/tlfe/*[/url]
// @exclude [url=http://www.teamliquid.net/tournaments/*]http://www.teamliquid.net/tournaments/*[/url]
// @exclude [url=http://www.teamliquid.net/vods/*]http://www.teamliquid.net/vods/*[/url]
// @run-at document-end
// ==/UserScript==

/* Notes: This should be fully compatible with Firefox (Greasemonkey)/Chrome/Opera.
* Opera users should replace the .user.js extension with just a .js before putting it into the userjs directory.
*
* Changelog:
* 2.4: Changed the link when clicking on the TLPD banner to go directly to the BW TLPD
* 2.3: Fixed the script run time to properly change everything before the page shows up on all 3 browsers
* 2.2: Swapped store and power rank links on the top bar
* Moved around the order in which the default changes take place so more visibly obvious changes occur first (before the page fully loads)
* 2.1: Added all of teamliquid and blacklisted specific pages to run the script on, instead of whitelisting every individual page
* 2.0: Abstracted the section relocation stuff
*/

/* Sections: news, general, sc2, bw, games, blogs, replays, calendar, streams, tlpd, liquipedia, tsl, poll */

// Wrap the script in an anonymous function so Opera doesn't blow up
(function() {

function main() {
var news = new Section("nav_news_left_mid", 1, false);
var general = new Section("nav_general", 1, false);
var sc2 = new Section("nav_starcraft2", 1, false);
var bw = new Section("nav_broodwar", 1, false);
var games = new Section("nav_games", 1, false);
var blogs = new Section("nav_blogs", 1, false);
var replays = new Section("nav_replays", 1, false);

var calendar = new Section("nav_calendar", 2, true);
var streams = new Section("nav_streams", 1, true);
var tlpd = new Section("nav_tlpd", 1, true);
var liquipedia = new Section("nav_wiki", 1, true);
var tsl = new Section("nav_tslforum", 1, true);
var poll = new Section("nav_poll", 1, true);

/* Swap Power Rank and Store */
var links = document.getElementsByTagName("a");
for (var i = 0; i < links.length; i++) {
if (links[i].getAttribute("href") == "/powerrank/") {
links[i].href = "/store/";
links[i].innerHTML = "Store";
}
else if (links[i].getAttribute("href") == "/store/") {
links[i].href = "/powerrank/";
links[i].innerHTML = "Power Rank";
}
}

/* Remove SC2 Elo rank display */
var rank1 = nextObject(document.forms.namedItem("frm_tlpd_search"));
var rank2 = nextObject(rank1);
rank1.parentNode.removeChild(rank1);
rank2.parentNode.removeChild(rank2);

/* Move the Brood War forums above the SC2 forums */
move_section(bw, sc2);

/* Move replays to above poll */
move_section(replays, poll);

/* Remove poll */
remove_section(poll);

/* Only BW streams are important to me */
let_bw_streams_rule_the_featured_list();

/* Move streams to above TSL */
move_section(streams, tsl);

/* Change default tlpd search to BW (Korea) */
document.forms.namedItem("frm_tlpd_search").elements.namedItem("type").children[3].selected = true;
document.getElementById("nav_tlpd").href = "/tlpd/korean";

/* Change liquipedia search to Brood War liquipedia */
for (var i = 0; i < document.forms.length; i++) {
var form = document.forms[i];
if (form.action == "http://wiki.teamliquid.net/starcraft2/index.php")
form.action = "http://wiki.teamliquid.net/starcraft/index.php";
}

}

function Section(id, count, on_right) {
this.on_right = on_right;
this.elements = new Array();

var link = document.getElementById(id);
this.elements.push(link);
for (var x = 0; x < count; x++) {
this.elements.push(nextObject(link));
}
}

var remove_section = function(section) {
for (var x = 0; x < section.elements.length; x++) {
var node = section.elements[x];
node.parentNode.removeChild(node);
}
}

var prepend_section = function(section, location) {
var loc = location.elements[0];
for (var x = 0; x < section.elements.length; x++) {
var node = section.elements[x];
loc.parentNode.insertBefore(node, loc);
}
}

var move_section = function(from, to) {
remove_section(from);
prepend_section(from, to);
}

var let_bw_streams_rule_the_featured_list = function() {
var bwNodes = new Array();

// get all the bw streams
var featuredStreams = nextObject(document.getElementById("nav_streams"));
featuredStreams = nextObject(featuredStreams.firstChild).firstChild.firstChild;
for (var i=0; i < featuredStreams.childNodes.length; i++) {
var node = featuredStreams.childNodes[i];
if (node.nodeName == "A" && node.innerHTML.indexOf("[BW] ") != -1) {
bwNodes.push(node);
}
}

var moreStreams = document.getElementById("more_streams");
for (var i=0; i < moreStreams.childNodes.length; i++) {
var node = moreStreams.childNodes[i];
if (node.nodeName == "A" && node.innerHTML.indexOf("[BW] ") != -1) {
bwNodes.push(node);
}
}

// remove all the old featured streams
while (featuredStreams.hasChildNodes()) {
featuredStreams.removeChild(featuredStreams.firstChild);
}

// insert bw streams into the featured streams list
for (var i=0; i < bwNodes.length; i++) {
featuredStreams.appendChild(bwNodes[i];
featuredStreams.appendChild(document.createElement("br"));
}
}

/* Adapted from [url=http://v3.thewatchmakerproject.com/journal/329/]http://v3.thewatchmakerproject.com/journal/329/[/url] */
var nextObject = function(el) {
var n = el;
do n = n.nextSibling;
while (n && n.nodeType != 1);
return n;
}

var previousObject = function(el) {
var p = el;
do p = p.previousSibling;
while (p && p.nodeType != 1);
return p;
}

if (window.opera) {
if (document.readyState==="loading") {
if (window.addEventListener)
window.addEventListener("DOMContentLoaded", main, false);
else if (window.attachEvent)
window.attachEvent("onload", main);
}
else if (document.readyState==="complete") {
main();
}
else {
if (window.addEventListener)
window.addEventListener("load", main, false);
else if (window.attachEvent)
window.attachEvent("onload", main);
}
}
else {
main();
}
})();



Ha, thanks for this. I've always been meaning to write a stream filter, but I was too lazy. I'll just use yours
When you want something, all the universe conspires in helping you to achieve it.
kuroshiroi
Profile Joined November 2010
3149 Posts
August 24 2011 21:26 GMT
#68
*Waits for somebody to program a BW calendar parser*

I'm hacking something together as we speak but I have no idea if it'll work...
Fly Jaedong, fly!
GolemMadness
Profile Blog Joined September 2010
Canada11044 Posts
August 24 2011 21:41 GMT
#69
It doesn't let me install for some reason. I click install, but nothing happens. I'm using Firefox 3.6.20
http://na.op.gg/summoner/userName=FLABREZU
Lucumo
Profile Joined January 2010
6850 Posts
Last Edited: 2011-08-24 21:51:52
August 24 2011 21:49 GMT
#70
Use the latest greasemonkey version.

https://addons.mozilla.org/en-US/firefox/addon/greasemonkey/versions/

Here is the problem which was fixed in 0.9.9:
"(Affecting 0.9.8) Scripts would not install (all scripts in Firefox 3: #1389, always for certain scripts: #1391)"
Reyis
Profile Joined August 2009
Pitcairn287 Posts
Last Edited: 2011-08-24 21:54:56
August 24 2011 21:52 GMT
#71
this stream script is so great. no wonder why BW streams have died long ago thanks to the flood of annoying SC2 streams right over there this will definetly help us to follow bw streams more smoothly!!!

next step: move PR from features at top to right bar and replace it with SC2 elo ranks!

that would have been the final touch :D


awesome job btw! big thanks!
기적의 혁명가 김택용 화이팅~!!
Taekwon
Profile Joined May 2010
United States8155 Posts
August 24 2011 22:22 GMT
#72
Does this work for the newest, newest version of Firefox?
▲ ▲ ▲
jpak
Profile Blog Joined October 2009
United States5045 Posts
August 24 2011 22:23 GMT
#73
On August 25 2011 02:27 WhuazGoodJaggah wrote:
I added a function to remove all streams except bw streams.
let bw streams rule tl.net MUAHAHAHHAHAH
var let_bw_streams_rule_the_featured_list = function() {
var bwNodes = new Array();

// get all the bw streams
var featuredStreams = nextObject(document.getElementById("nav_streams"));
featuredStreams = nextObject(featuredStreams.firstChild).firstChild.firstChild;
for (var i=0; i < featuredStreams.childNodes.length; i++) {
var node = featuredStreams.childNodes[i];
if (node.nodeName == "A" && node.innerHTML.indexOf("[BW] ") != -1) {
bwNodes.push(node);
}
}

var moreStreams = document.getElementById("more_streams");
for (var i=0; i < moreStreams.childNodes.length; i++) {
var node = moreStreams.childNodes[i];
if (node.nodeName == "A" && node.innerHTML.indexOf("[BW] ") != -1) {
bwNodes.push(node);
}
}

// remove all the old featured streams
while (featuredStreams.hasChildNodes()) {
featuredStreams.removeChild(featuredStreams.firstChild);
}

// insert bw streams into the featured streams list
for (var i=0; i < bwNodes.length; i++) {
featuredStreams.appendChild(bwNodes[i]);
featuredStreams.appendChild(document.createElement("br"));
}
}


just insert the function somewhere between other functions (f.e. below move_section) and then call it where the other functions (like move_section) are called.

+ Show Spoiler [full script] +
// ==UserScript==
// @name TLBW
// @description Userscript to make teamliquid more useful for Brood War fans
// @version 2.4
// @include [url=http://teamliquid.net/*]http://teamliquid.net/*[/url]
// @include [url=http://www.teamliquid.net/*]http://www.teamliquid.net/*[/url]
// @exclude [url=http://teamliquid.net/sc2/*]http://teamliquid.net/sc2/*[/url]
// @exclude [url=http://teamliquid.net/store/*]http://teamliquid.net/store/*[/url]
// @exclude [url=http://teamliquid.net/tlfe/*]http://teamliquid.net/tlfe/*[/url]
// @exclude [url=http://teamliquid.net/tournaments/*]http://teamliquid.net/tournaments/*[/url]
// @exclude [url=http://teamliquid.net/vods/*]http://teamliquid.net/vods/*[/url]
// @exclude [url=http://www.teamliquid.net/sc2/*]http://www.teamliquid.net/sc2/*[/url]
// @exclude [url=http://www.teamliquid.net/store/*]http://www.teamliquid.net/store/*[/url]
// @exclude [url=http://www.teamliquid.net/tlfe/*]http://www.teamliquid.net/tlfe/*[/url]
// @exclude [url=http://www.teamliquid.net/tournaments/*]http://www.teamliquid.net/tournaments/*[/url]
// @exclude [url=http://www.teamliquid.net/vods/*]http://www.teamliquid.net/vods/*[/url]
// @run-at document-end
// ==/UserScript==

/* Notes: This should be fully compatible with Firefox (Greasemonkey)/Chrome/Opera.
* Opera users should replace the .user.js extension with just a .js before putting it into the userjs directory.
*
* Changelog:
* 2.4: Changed the link when clicking on the TLPD banner to go directly to the BW TLPD
* 2.3: Fixed the script run time to properly change everything before the page shows up on all 3 browsers
* 2.2: Swapped store and power rank links on the top bar
* Moved around the order in which the default changes take place so more visibly obvious changes occur first (before the page fully loads)
* 2.1: Added all of teamliquid and blacklisted specific pages to run the script on, instead of whitelisting every individual page
* 2.0: Abstracted the section relocation stuff
*/

/* Sections: news, general, sc2, bw, games, blogs, replays, calendar, streams, tlpd, liquipedia, tsl, poll */

// Wrap the script in an anonymous function so Opera doesn't blow up
(function() {

function main() {
var news = new Section("nav_news_left_mid", 1, false);
var general = new Section("nav_general", 1, false);
var sc2 = new Section("nav_starcraft2", 1, false);
var bw = new Section("nav_broodwar", 1, false);
var games = new Section("nav_games", 1, false);
var blogs = new Section("nav_blogs", 1, false);
var replays = new Section("nav_replays", 1, false);

var calendar = new Section("nav_calendar", 2, true);
var streams = new Section("nav_streams", 1, true);
var tlpd = new Section("nav_tlpd", 1, true);
var liquipedia = new Section("nav_wiki", 1, true);
var tsl = new Section("nav_tslforum", 1, true);
var poll = new Section("nav_poll", 1, true);

/* Swap Power Rank and Store */
var links = document.getElementsByTagName("a");
for (var i = 0; i < links.length; i++) {
if (links[i].getAttribute("href") == "/powerrank/") {
links[i].href = "/store/";
links[i].innerHTML = "Store";
}
else if (links[i].getAttribute("href") == "/store/") {
links[i].href = "/powerrank/";
links[i].innerHTML = "Power Rank";
}
}

/* Remove SC2 Elo rank display */
var rank1 = nextObject(document.forms.namedItem("frm_tlpd_search"));
var rank2 = nextObject(rank1);
rank1.parentNode.removeChild(rank1);
rank2.parentNode.removeChild(rank2);

/* Move the Brood War forums above the SC2 forums */
move_section(bw, sc2);

/* Move replays to above poll */
move_section(replays, poll);

/* Remove poll */
remove_section(poll);

/* Only BW streams are important to me */
let_bw_streams_rule_the_featured_list();

/* Move streams to above TSL */
move_section(streams, tsl);

/* Change default tlpd search to BW (Korea) */
document.forms.namedItem("frm_tlpd_search").elements.namedItem("type").children[3].selected = true;
document.getElementById("nav_tlpd").href = "/tlpd/korean";

/* Change liquipedia search to Brood War liquipedia */
for (var i = 0; i < document.forms.length; i++) {
var form = document.forms[i];
if (form.action == "http://wiki.teamliquid.net/starcraft2/index.php")
form.action = "http://wiki.teamliquid.net/starcraft/index.php";
}

}

function Section(id, count, on_right) {
this.on_right = on_right;
this.elements = new Array();

var link = document.getElementById(id);
this.elements.push(link);
for (var x = 0; x < count; x++) {
this.elements.push(nextObject(link));
}
}

var remove_section = function(section) {
for (var x = 0; x < section.elements.length; x++) {
var node = section.elements[x];
node.parentNode.removeChild(node);
}
}

var prepend_section = function(section, location) {
var loc = location.elements[0];
for (var x = 0; x < section.elements.length; x++) {
var node = section.elements[x];
loc.parentNode.insertBefore(node, loc);
}
}

var move_section = function(from, to) {
remove_section(from);
prepend_section(from, to);
}

var let_bw_streams_rule_the_featured_list = function() {
var bwNodes = new Array();

// get all the bw streams
var featuredStreams = nextObject(document.getElementById("nav_streams"));
featuredStreams = nextObject(featuredStreams.firstChild).firstChild.firstChild;
for (var i=0; i < featuredStreams.childNodes.length; i++) {
var node = featuredStreams.childNodes[i];
if (node.nodeName == "A" && node.innerHTML.indexOf("[BW] ") != -1) {
bwNodes.push(node);
}
}

var moreStreams = document.getElementById("more_streams");
for (var i=0; i < moreStreams.childNodes.length; i++) {
var node = moreStreams.childNodes[i];
if (node.nodeName == "A" && node.innerHTML.indexOf("[BW] ") != -1) {
bwNodes.push(node);
}
}

// remove all the old featured streams
while (featuredStreams.hasChildNodes()) {
featuredStreams.removeChild(featuredStreams.firstChild);
}

// insert bw streams into the featured streams list
for (var i=0; i < bwNodes.length; i++) {
featuredStreams.appendChild(bwNodes[i];
featuredStreams.appendChild(document.createElement("br"));
}
}

/* Adapted from [url=http://v3.thewatchmakerproject.com/journal/329/]http://v3.thewatchmakerproject.com/journal/329/[/url] */
var nextObject = function(el) {
var n = el;
do n = n.nextSibling;
while (n && n.nodeType != 1);
return n;
}

var previousObject = function(el) {
var p = el;
do p = p.previousSibling;
while (p && p.nodeType != 1);
return p;
}

if (window.opera) {
if (document.readyState==="loading") {
if (window.addEventListener)
window.addEventListener("DOMContentLoaded", main, false);
else if (window.attachEvent)
window.attachEvent("onload", main);
}
else if (document.readyState==="complete") {
main();
}
else {
if (window.addEventListener)
window.addEventListener("load", main, false);
else if (window.attachEvent)
window.attachEvent("onload", main);
}
}
else {
main();
}
})();


when I try the full script, it says an 800A03F4 error with "expected /" on line 94 char 49.

Love the efforts, everyone!!
CJ Entusman #50! #1 클템 fan TL!
KTF_CloaK
Profile Blog Joined July 2010
Netherlands1338 Posts
August 24 2011 22:35 GMT
#74
Would be perfect if it removed every sc2 stream and event on the calendar, yeah really perfect.

BW for life :3
KT Rolster for the win!! Lee-Young-Ho hwaiting!!
Cambium
Profile Blog Joined June 2004
United States16368 Posts
August 24 2011 22:46 GMT
#75
The calendar wouldn't be too hard to fix, as long as there are keywords associated with BW events like

[OSL]
[MSL]
[SPL]
[STX]
etc.

It can be more or less the same as the stream filter.
When you want something, all the universe conspires in helping you to achieve it.
alexpnd
Profile Blog Joined March 2009
Canada1857 Posts
August 24 2011 23:22 GMT
#76
Does browser js have xml node type constants? It's a real bugger seeing nodeType == 1 Nice work though.
www.brainyweb.ca //web stuff!
quirinus
Profile Blog Joined May 2007
Croatia2489 Posts
August 24 2011 23:34 GMT
#77
There was already something similar in this topic:

http://www.teamliquid.net/forum/viewpost.php?post_id=8467075

I even had the stream filter. But yours this better, especially with this new layout of the page.
All candles lit within him, and there was purity. | First auto-promoted BW LP editor.
Zamkis
Profile Joined July 2009
Canada114 Posts
August 25 2011 00:17 GMT
#78
This is truly amazing. I've been waiting for something like this for so long. From the bottom of my heart, thank you so much. If we can get the Power Rank back and make all the SC2 stuff disappear then it'll be like the good old TL!
Destruction is a work of an afternoon, Creation is a work of a lifetime.
TheGlassface
Profile Joined November 2010
United States612 Posts
August 25 2011 01:03 GMT
#79
Dude, this is slammin.
Any chance the calendar for chrome can be done so it shows only BW events and streams?
I would gladly pitch some e hugs to someone for this
The mystery of life is not a problem to solve, but a reality to experience. **Hang in there STX fans!! Kal Hwaiting!**
r3z3nd3
Profile Blog Joined November 2007
Brazil522 Posts
August 25 2011 01:29 GMT
#80
Thanks, that`s exactly what I needed. BW Forever
Born to fast expand
WhuazGoodJaggah
Profile Blog Joined January 2009
Lesotho777 Posts
Last Edited: 2011-08-25 01:36:23
August 25 2011 01:36 GMT
#81
On August 25 2011 07:23 jpak wrote:
Show nested quote +
On August 25 2011 02:27 WhuazGoodJaggah wrote:
I added a function to remove all streams except bw streams.
let bw streams rule tl.net MUAHAHAHHAHAH
var let_bw_streams_rule_the_featured_list = function() {
var bwNodes = new Array();

// get all the bw streams
var featuredStreams = nextObject(document.getElementById("nav_streams"));
featuredStreams = nextObject(featuredStreams.firstChild).firstChild.firstChild;
for (var i=0; i < featuredStreams.childNodes.length; i++) {
var node = featuredStreams.childNodes[i];
if (node.nodeName == "A" && node.innerHTML.indexOf("[BW] ") != -1) {
bwNodes.push(node);
}
}

var moreStreams = document.getElementById("more_streams");
for (var i=0; i < moreStreams.childNodes.length; i++) {
var node = moreStreams.childNodes[i];
if (node.nodeName == "A" && node.innerHTML.indexOf("[BW] ") != -1) {
bwNodes.push(node);
}
}

// remove all the old featured streams
while (featuredStreams.hasChildNodes()) {
featuredStreams.removeChild(featuredStreams.firstChild);
}

// insert bw streams into the featured streams list
for (var i=0; i < bwNodes.length; i++) {
featuredStreams.appendChild(bwNodes[i]);
featuredStreams.appendChild(document.createElement("br"));
}
}


just insert the function somewhere between other functions (f.e. below move_section) and then call it where the other functions (like move_section) are called.

+ Show Spoiler [full script] +
// ==UserScript==
// @name TLBW
// @description Userscript to make teamliquid more useful for Brood War fans
// @version 2.4
// @include [url=http://teamliquid.net/*]http://teamliquid.net/*[/url]
// @include [url=http://www.teamliquid.net/*]http://www.teamliquid.net/*[/url]
// @exclude [url=http://teamliquid.net/sc2/*]http://teamliquid.net/sc2/*[/url]
// @exclude [url=http://teamliquid.net/store/*]http://teamliquid.net/store/*[/url]
// @exclude [url=http://teamliquid.net/tlfe/*]http://teamliquid.net/tlfe/*[/url]
// @exclude [url=http://teamliquid.net/tournaments/*]http://teamliquid.net/tournaments/*[/url]
// @exclude [url=http://teamliquid.net/vods/*]http://teamliquid.net/vods/*[/url]
// @exclude [url=http://www.teamliquid.net/sc2/*]http://www.teamliquid.net/sc2/*[/url]
// @exclude [url=http://www.teamliquid.net/store/*]http://www.teamliquid.net/store/*[/url]
// @exclude [url=http://www.teamliquid.net/tlfe/*]http://www.teamliquid.net/tlfe/*[/url]
// @exclude [url=http://www.teamliquid.net/tournaments/*]http://www.teamliquid.net/tournaments/*[/url]
// @exclude [url=http://www.teamliquid.net/vods/*]http://www.teamliquid.net/vods/*[/url]
// @run-at document-end
// ==/UserScript==

/* Notes: This should be fully compatible with Firefox (Greasemonkey)/Chrome/Opera.
* Opera users should replace the .user.js extension with just a .js before putting it into the userjs directory.
*
* Changelog:
* 2.4: Changed the link when clicking on the TLPD banner to go directly to the BW TLPD
* 2.3: Fixed the script run time to properly change everything before the page shows up on all 3 browsers
* 2.2: Swapped store and power rank links on the top bar
* Moved around the order in which the default changes take place so more visibly obvious changes occur first (before the page fully loads)
* 2.1: Added all of teamliquid and blacklisted specific pages to run the script on, instead of whitelisting every individual page
* 2.0: Abstracted the section relocation stuff
*/

/* Sections: news, general, sc2, bw, games, blogs, replays, calendar, streams, tlpd, liquipedia, tsl, poll */

// Wrap the script in an anonymous function so Opera doesn't blow up
(function() {

function main() {
var news = new Section("nav_news_left_mid", 1, false);
var general = new Section("nav_general", 1, false);
var sc2 = new Section("nav_starcraft2", 1, false);
var bw = new Section("nav_broodwar", 1, false);
var games = new Section("nav_games", 1, false);
var blogs = new Section("nav_blogs", 1, false);
var replays = new Section("nav_replays", 1, false);

var calendar = new Section("nav_calendar", 2, true);
var streams = new Section("nav_streams", 1, true);
var tlpd = new Section("nav_tlpd", 1, true);
var liquipedia = new Section("nav_wiki", 1, true);
var tsl = new Section("nav_tslforum", 1, true);
var poll = new Section("nav_poll", 1, true);

/* Swap Power Rank and Store */
var links = document.getElementsByTagName("a");
for (var i = 0; i < links.length; i++) {
if (links[i].getAttribute("href") == "/powerrank/") {
links[i].href = "/store/";
links[i].innerHTML = "Store";
}
else if (links[i].getAttribute("href") == "/store/") {
links[i].href = "/powerrank/";
links[i].innerHTML = "Power Rank";
}
}

/* Remove SC2 Elo rank display */
var rank1 = nextObject(document.forms.namedItem("frm_tlpd_search"));
var rank2 = nextObject(rank1);
rank1.parentNode.removeChild(rank1);
rank2.parentNode.removeChild(rank2);

/* Move the Brood War forums above the SC2 forums */
move_section(bw, sc2);

/* Move replays to above poll */
move_section(replays, poll);

/* Remove poll */
remove_section(poll);

/* Only BW streams are important to me */
let_bw_streams_rule_the_featured_list();

/* Move streams to above TSL */
move_section(streams, tsl);

/* Change default tlpd search to BW (Korea) */
document.forms.namedItem("frm_tlpd_search").elements.namedItem("type").children[3].selected = true;
document.getElementById("nav_tlpd").href = "/tlpd/korean";

/* Change liquipedia search to Brood War liquipedia */
for (var i = 0; i < document.forms.length; i++) {
var form = document.forms[i];
if (form.action == "http://wiki.teamliquid.net/starcraft2/index.php")
form.action = "http://wiki.teamliquid.net/starcraft/index.php";
}

}

function Section(id, count, on_right) {
this.on_right = on_right;
this.elements = new Array();

var link = document.getElementById(id);
this.elements.push(link);
for (var x = 0; x < count; x++) {
this.elements.push(nextObject(link));
}
}

var remove_section = function(section) {
for (var x = 0; x < section.elements.length; x++) {
var node = section.elements[x];
node.parentNode.removeChild(node);
}
}

var prepend_section = function(section, location) {
var loc = location.elements[0];
for (var x = 0; x < section.elements.length; x++) {
var node = section.elements[x];
loc.parentNode.insertBefore(node, loc);
}
}

var move_section = function(from, to) {
remove_section(from);
prepend_section(from, to);
}

var let_bw_streams_rule_the_featured_list = function() {
var bwNodes = new Array();

// get all the bw streams
var featuredStreams = nextObject(document.getElementById("nav_streams"));
featuredStreams = nextObject(featuredStreams.firstChild).firstChild.firstChild;
for (var i=0; i < featuredStreams.childNodes.length; i++) {
var node = featuredStreams.childNodes[i];
if (node.nodeName == "A" && node.innerHTML.indexOf("[BW] ") != -1) {
bwNodes.push(node);
}
}

var moreStreams = document.getElementById("more_streams");
for (var i=0; i < moreStreams.childNodes.length; i++) {
var node = moreStreams.childNodes[i];
if (node.nodeName == "A" && node.innerHTML.indexOf("[BW] ") != -1) {
bwNodes.push(node);
}
}

// remove all the old featured streams
while (featuredStreams.hasChildNodes()) {
featuredStreams.removeChild(featuredStreams.firstChild);
}

// insert bw streams into the featured streams list
for (var i=0; i < bwNodes.length; i++) {
featuredStreams.appendChild(bwNodes[i];
featuredStreams.appendChild(document.createElement("br"));
}
}

/* Adapted from [url=http://v3.thewatchmakerproject.com/journal/329/]http://v3.thewatchmakerproject.com/journal/329/[/url] */
var nextObject = function(el) {
var n = el;
do n = n.nextSibling;
while (n && n.nodeType != 1);
return n;
}

var previousObject = function(el) {
var p = el;
do p = p.previousSibling;
while (p && p.nodeType != 1);
return p;
}

if (window.opera) {
if (document.readyState==="loading") {
if (window.addEventListener)
window.addEventListener("DOMContentLoaded", main, false);
else if (window.attachEvent)
window.attachEvent("onload", main);
}
else if (document.readyState==="complete") {
main();
}
else {
if (window.addEventListener)
window.addEventListener("load", main, false);
else if (window.attachEvent)
window.attachEvent("onload", main);
}
}
else {
main();
}
})();


when I try the full script, it says an 800A03F4 error with "expected /" on line 94 char 49.

Love the efforts, everyone!!


I uploaded it to userscripts.org, http://userscripts.org/scripts/show/111240.
small dicks have great firepower
insanet
Profile Joined January 2010
Peru439 Posts
August 25 2011 01:44 GMT
#82
this is working great, thank you.
Cambium
Profile Blog Joined June 2004
United States16368 Posts
Last Edited: 2011-08-26 05:25:58
August 25 2011 01:55 GMT
#83
Filtered Calendar (code below)
[image loading]


http://userscripts.org/scripts/show/111242

notes:
- pretty messy, I just wanted it to work
- I removed the toggle button and show all events by default
- so far, only OSL, MSL, SPL and STX are shown, more can be added in isSCBW method by including additional tag
- there's nothing stopping you from adding your favourite SC2 tourneys such as "[GSL] "
- updated on 08/26/2011


// ==UserScript==
// @name calendar fix
// @namespace tl
// @include h__p://www.teamliquid.net/*
// ==/UserScript==
//
//

// show all and hide the toggle
var toggle = document.getElementById( "span_more_events" );
toggle.style.display = "block";
toggle = document.getElementById( "link_show_more_events" );
toggle.style.display = "none";

// 'less' events
var node;
var par;
var parentXPath;
var nodeXPath;
for( i = 1; i <= 5; i++ ) {
nodeXPath = "/html/body/table/tbody/tr/td/table[2]/tbody/tr/td[3]/table/tbody/tr/td/div[2]/table/tbody/tr[" + i + "]/td[2]/a";
node = findXPathNode( nodeXPath );
if( !isSCBW( node ) ){
parentXPath = "/html/body/table/tbody/tr/td/table[2]/tbody/tr/td[3]/table/tbody/tr/td/div[2]/table/tbody/tr[" + i + "]";
par = findXPathNode( parentXPath );
par.style.display = "none";
}
}
// 'more' events
for( i = 1; i <= 15; i++ ){
nodeXPath = "/html/body/table/tbody/tr/td/table[2]/tbody/tr/td[3]/table/tbody/tr/td/div[2]/div[2]/table/tbody/tr[" + i + "]/td[2]/a";
node = findXPathNode( nodeXPath );
if( !isSCBW( node ) ){
parentXPath = "/html/body/table/tbody/tr/td/table[2]/tbody/tr/td[3]/table/tbody/tr/td/div[2]/div[2]/table/tbody/tr[" + i + "]";
par = findXPathNode( parentXPath );
par.style.display = "none";
}
}

function isSCBW( node )
{
var tags = new Array( "[OSL] ", "[MSL] ", "[SPL] ", "[STX] ", "[GC] " ); // GC = Gambit Cup
var str = node.innerHTML;
for (var i in tags) {
if (str.indexOf(tags[i]) != -1) {
return true;
}
}
return false;
}

function findXPathNode(xpath, start,doc)
{
var result = (doc == null ? document : doc).evaluate(xpath,(start == null ? document : start), null, XPathResult.ORDERED_NODE_SNAPSHOT_TYPE ,null);
return (result.snapshotLength > 0 ? result.snapshotItem(0) : null);
}
When you want something, all the universe conspires in helping you to achieve it.
WhuazGoodJaggah
Profile Blog Joined January 2009
Lesotho777 Posts
Last Edited: 2011-08-25 02:16:22
August 25 2011 02:10 GMT
#84
niceööö
A little suggestion for isSCBW, to make it easier to add and remove tags
function isSCBW( node )
{
var tags = new Array( "[OSL] ", "[MSL] ", "[SPL] ", "[STX] ", "[GC] " ); // GC = Gambit Cup
var str = node.innerHTML;
for (var i in tags) {
if (str.indexOf(tags[i]) != -1) {
return true;
}
}
return false;
}
small dicks have great firepower
soujiro_
Profile Joined June 2010
Uruguay5195 Posts
August 25 2011 02:14 GMT
#85
On August 25 2011 10:36 WhuazGoodJaggah wrote:
Show nested quote +
On August 25 2011 07:23 jpak wrote:
On August 25 2011 02:27 WhuazGoodJaggah wrote:
I added a function to remove all streams except bw streams.
let bw streams rule tl.net MUAHAHAHHAHAH
var let_bw_streams_rule_the_featured_list = function() {
var bwNodes = new Array();

// get all the bw streams
var featuredStreams = nextObject(document.getElementById("nav_streams"));
featuredStreams = nextObject(featuredStreams.firstChild).firstChild.firstChild;
for (var i=0; i < featuredStreams.childNodes.length; i++) {
var node = featuredStreams.childNodes[i];
if (node.nodeName == "A" && node.innerHTML.indexOf("[BW] ") != -1) {
bwNodes.push(node);
}
}

var moreStreams = document.getElementById("more_streams");
for (var i=0; i < moreStreams.childNodes.length; i++) {
var node = moreStreams.childNodes[i];
if (node.nodeName == "A" && node.innerHTML.indexOf("[BW] ") != -1) {
bwNodes.push(node);
}
}

// remove all the old featured streams
while (featuredStreams.hasChildNodes()) {
featuredStreams.removeChild(featuredStreams.firstChild);
}

// insert bw streams into the featured streams list
for (var i=0; i < bwNodes.length; i++) {
featuredStreams.appendChild(bwNodes[i]);
featuredStreams.appendChild(document.createElement("br"));
}
}


just insert the function somewhere between other functions (f.e. below move_section) and then call it where the other functions (like move_section) are called.

+ Show Spoiler [full script] +
// ==UserScript==
// @name TLBW
// @description Userscript to make teamliquid more useful for Brood War fans
// @version 2.4
// @include [url=http://teamliquid.net/*]http://teamliquid.net/*[/url]
// @include [url=http://www.teamliquid.net/*]http://www.teamliquid.net/*[/url]
// @exclude [url=http://teamliquid.net/sc2/*]http://teamliquid.net/sc2/*[/url]
// @exclude [url=http://teamliquid.net/store/*]http://teamliquid.net/store/*[/url]
// @exclude [url=http://teamliquid.net/tlfe/*]http://teamliquid.net/tlfe/*[/url]
// @exclude [url=http://teamliquid.net/tournaments/*]http://teamliquid.net/tournaments/*[/url]
// @exclude [url=http://teamliquid.net/vods/*]http://teamliquid.net/vods/*[/url]
// @exclude [url=http://www.teamliquid.net/sc2/*]http://www.teamliquid.net/sc2/*[/url]
// @exclude [url=http://www.teamliquid.net/store/*]http://www.teamliquid.net/store/*[/url]
// @exclude [url=http://www.teamliquid.net/tlfe/*]http://www.teamliquid.net/tlfe/*[/url]
// @exclude [url=http://www.teamliquid.net/tournaments/*]http://www.teamliquid.net/tournaments/*[/url]
// @exclude [url=http://www.teamliquid.net/vods/*]http://www.teamliquid.net/vods/*[/url]
// @run-at document-end
// ==/UserScript==

/* Notes: This should be fully compatible with Firefox (Greasemonkey)/Chrome/Opera.
* Opera users should replace the .user.js extension with just a .js before putting it into the userjs directory.
*
* Changelog:
* 2.4: Changed the link when clicking on the TLPD banner to go directly to the BW TLPD
* 2.3: Fixed the script run time to properly change everything before the page shows up on all 3 browsers
* 2.2: Swapped store and power rank links on the top bar
* Moved around the order in which the default changes take place so more visibly obvious changes occur first (before the page fully loads)
* 2.1: Added all of teamliquid and blacklisted specific pages to run the script on, instead of whitelisting every individual page
* 2.0: Abstracted the section relocation stuff
*/

/* Sections: news, general, sc2, bw, games, blogs, replays, calendar, streams, tlpd, liquipedia, tsl, poll */

// Wrap the script in an anonymous function so Opera doesn't blow up
(function() {

function main() {
var news = new Section("nav_news_left_mid", 1, false);
var general = new Section("nav_general", 1, false);
var sc2 = new Section("nav_starcraft2", 1, false);
var bw = new Section("nav_broodwar", 1, false);
var games = new Section("nav_games", 1, false);
var blogs = new Section("nav_blogs", 1, false);
var replays = new Section("nav_replays", 1, false);

var calendar = new Section("nav_calendar", 2, true);
var streams = new Section("nav_streams", 1, true);
var tlpd = new Section("nav_tlpd", 1, true);
var liquipedia = new Section("nav_wiki", 1, true);
var tsl = new Section("nav_tslforum", 1, true);
var poll = new Section("nav_poll", 1, true);

/* Swap Power Rank and Store */
var links = document.getElementsByTagName("a");
for (var i = 0; i < links.length; i++) {
if (links[i].getAttribute("href") == "/powerrank/") {
links[i].href = "/store/";
links[i].innerHTML = "Store";
}
else if (links[i].getAttribute("href") == "/store/") {
links[i].href = "/powerrank/";
links[i].innerHTML = "Power Rank";
}
}

/* Remove SC2 Elo rank display */
var rank1 = nextObject(document.forms.namedItem("frm_tlpd_search"));
var rank2 = nextObject(rank1);
rank1.parentNode.removeChild(rank1);
rank2.parentNode.removeChild(rank2);

/* Move the Brood War forums above the SC2 forums */
move_section(bw, sc2);

/* Move replays to above poll */
move_section(replays, poll);

/* Remove poll */
remove_section(poll);

/* Only BW streams are important to me */
let_bw_streams_rule_the_featured_list();

/* Move streams to above TSL */
move_section(streams, tsl);

/* Change default tlpd search to BW (Korea) */
document.forms.namedItem("frm_tlpd_search").elements.namedItem("type").children[3].selected = true;
document.getElementById("nav_tlpd").href = "/tlpd/korean";

/* Change liquipedia search to Brood War liquipedia */
for (var i = 0; i < document.forms.length; i++) {
var form = document.forms[i];
if (form.action == "http://wiki.teamliquid.net/starcraft2/index.php")
form.action = "http://wiki.teamliquid.net/starcraft/index.php";
}

}

function Section(id, count, on_right) {
this.on_right = on_right;
this.elements = new Array();

var link = document.getElementById(id);
this.elements.push(link);
for (var x = 0; x < count; x++) {
this.elements.push(nextObject(link));
}
}

var remove_section = function(section) {
for (var x = 0; x < section.elements.length; x++) {
var node = section.elements[x];
node.parentNode.removeChild(node);
}
}

var prepend_section = function(section, location) {
var loc = location.elements[0];
for (var x = 0; x < section.elements.length; x++) {
var node = section.elements[x];
loc.parentNode.insertBefore(node, loc);
}
}

var move_section = function(from, to) {
remove_section(from);
prepend_section(from, to);
}

var let_bw_streams_rule_the_featured_list = function() {
var bwNodes = new Array();

// get all the bw streams
var featuredStreams = nextObject(document.getElementById("nav_streams"));
featuredStreams = nextObject(featuredStreams.firstChild).firstChild.firstChild;
for (var i=0; i < featuredStreams.childNodes.length; i++) {
var node = featuredStreams.childNodes[i];
if (node.nodeName == "A" && node.innerHTML.indexOf("[BW] ") != -1) {
bwNodes.push(node);
}
}

var moreStreams = document.getElementById("more_streams");
for (var i=0; i < moreStreams.childNodes.length; i++) {
var node = moreStreams.childNodes[i];
if (node.nodeName == "A" && node.innerHTML.indexOf("[BW] ") != -1) {
bwNodes.push(node);
}
}

// remove all the old featured streams
while (featuredStreams.hasChildNodes()) {
featuredStreams.removeChild(featuredStreams.firstChild);
}

// insert bw streams into the featured streams list
for (var i=0; i < bwNodes.length; i++) {
featuredStreams.appendChild(bwNodes[i];
featuredStreams.appendChild(document.createElement("br"));
}
}

/* Adapted from [url=http://v3.thewatchmakerproject.com/journal/329/]http://v3.thewatchmakerproject.com/journal/329/[/url] */
var nextObject = function(el) {
var n = el;
do n = n.nextSibling;
while (n && n.nodeType != 1);
return n;
}

var previousObject = function(el) {
var p = el;
do p = p.previousSibling;
while (p && p.nodeType != 1);
return p;
}

if (window.opera) {
if (document.readyState==="loading") {
if (window.addEventListener)
window.addEventListener("DOMContentLoaded", main, false);
else if (window.attachEvent)
window.attachEvent("onload", main);
}
else if (document.readyState==="complete") {
main();
}
else {
if (window.addEventListener)
window.addEventListener("load", main, false);
else if (window.attachEvent)
window.attachEvent("onload", main);
}
}
else {
main();
}
})();


when I try the full script, it says an 800A03F4 error with "expected /" on line 94 char 49.

Love the efforts, everyone!!


I uploaded it to userscripts.org, http://userscripts.org/scripts/show/111240.


thanks for the upload, i was having issues trying to install it
ace hwaiting!!
Cambium
Profile Blog Joined June 2004
United States16368 Posts
August 25 2011 02:15 GMT
#86
On August 25 2011 11:10 WhuazGoodJaggah wrote:
niceööö
A little suggestion for isSCBW, to make it easier to add and remove tags
function isSCBW( node )
{
var tags = new Array( "[OSL] ", "[MSL] ", "[SPL] ", "[STX] ", "[GC] " ); // GC = Gambit Cup
var str = node.innerHTML;
for (var i in tags) {
if (str.indexOf(tags[i]) != -1) {
return true;
}
}
return false;
}

Yep, this is much easier, let me update it.
When you want something, all the universe conspires in helping you to achieve it.
sheaRZerg
Profile Blog Joined June 2009
United States613 Posts
August 25 2011 02:15 GMT
#87
This is awesome.

Thanks to everyone working on it.
"Dude, just don't listen to what I say; listen to what I mean." -Sean Plott
erin[go]bragh
Profile Joined December 2008
United States815 Posts
August 25 2011 02:44 GMT
#88
Amazing! Huge props to everyone working on it! Out of site, out of mind!

Getting rid of SC2 events on the calendar was the biggest thing for me. So hard to find BW event times in the sea of rubbish.

Now if only there were a way to remove posts like "OMG HOPE HE SWITCHES TO SC2 LAWL" in BW threads.
JulyZerg! by.hero, effOrt, KTY.
writer22816
Profile Blog Joined September 2008
United States5775 Posts
August 25 2011 03:04 GMT
#89
Changing the default TLPD search and cleansing the calendar? Wow this is absolutely amazing, can't wait to try this when I get home
8/4/12 never forget, never forgive.
therockmanxx
Profile Joined July 2010
Peru1174 Posts
August 25 2011 03:22 GMT
#90
can you jut make a script to remove sc2 forums ?? =D
Tekken ProGamer
Armathai
Profile Joined October 2007
1023 Posts
August 25 2011 03:44 GMT
#91
Amazing work b0lt! Chill said something about BW TL members needing to step up to help, and you've just done what R1CH doesn't have the time for and made our lives so much easier ^_^ <3 <3

@Cambium

I installed your script too (successfully) but it doesn't appear to be filtering out the SC2 events?
Thanks for the work anyway, hopefully I'll figure out what I'm doing wrong
Looking for ArcticCerebrate formerly from @USEast
4vvhiplash7
Profile Joined December 2010
South Africa392 Posts
August 25 2011 04:42 GMT
#92
On August 25 2011 11:44 erin[go]bragh wrote:
Amazing! Huge props to everyone working on it! Out of site, out of mind!

Getting rid of SC2 events on the calendar was the biggest thing for me. So hard to find BW event times in the sea of rubbish.

Now if only there were a way to remove posts like "OMG HOPE HE SWITCHES TO SC2 LAWL" in BW threads.


That would be amazing! LOL
AttackZerg
Profile Blog Joined January 2003
United States7454 Posts
August 25 2011 04:44 GMT
#93
Thank you guys!
CaucasianAsian
Profile Blog Joined September 2005
Korea (South)11576 Posts
August 25 2011 04:45 GMT
#94
Replays section doesn't show up when i use this extension.
Calendar@ Fish Server: `iOps]..Stark
Cambium
Profile Blog Joined June 2004
United States16368 Posts
August 25 2011 04:53 GMT
#95
On August 25 2011 12:44 Armathai wrote:
Amazing work b0lt! Chill said something about BW TL members needing to step up to help, and you've just done what R1CH doesn't have the time for and made our lives so much easier ^_^ <3 <3

@Cambium

I installed your script too (successfully) but it doesn't appear to be filtering out the SC2 events?
Thanks for the work anyway, hopefully I'll figure out what I'm doing wrong

That's strange, it seems to work for me.

Go to manage scripts --> calendar fix --[right click]-> edit

Do you see the source code in there?
When you want something, all the universe conspires in helping you to achieve it.
soujiro_
Profile Joined June 2010
Uruguay5195 Posts
August 25 2011 04:55 GMT
#96
On August 25 2011 13:45 CaucasianAsian wrote:
Replays section doesn't show up when i use this extension.



replays were moved to the right side, under tsl
ace hwaiting!!
CaucasianAsian
Profile Blog Joined September 2005
Korea (South)11576 Posts
August 25 2011 04:59 GMT
#97
oh ok thank you.
Calendar@ Fish Server: `iOps]..Stark
Sawamura
Profile Blog Joined August 2010
Malaysia7602 Posts
August 25 2011 05:16 GMT
#98
the calendar fix is awesome <3
BW/KT Forever R.I.P KT.Violet dearly missed ..
Cambium
Profile Blog Joined June 2004
United States16368 Posts
August 25 2011 05:22 GMT
#99
To OP:

Instead of looping through all forms, you can simply refer to liquipedia via its XPath:


var bwlpXPath = "/html/body/table/tbody/tr/td/table[2]/tbody/tr/td[3]/table[4]/tbody/tr/td/form";
node = findXPathNode( bwlpXPath );
node.action = "h__p://wiki.teamliquid.net/starcraft/index.php";
When you want something, all the universe conspires in helping you to achieve it.
HaruHaru
Profile Blog Joined November 2009
United States988 Posts
August 25 2011 06:15 GMT
#100
excellent post! this will help so much!
Long live BroodWar!
b0lt
Profile Joined March 2009
United States790 Posts
August 25 2011 06:25 GMT
#101
I split up the main script into individual scripts for each feature, I've got them up at http://code.google.com/p/teamliquidbw/source/browse/ now. Also, I polished up WhuazGoodJaggah's stream filter script a bit


On August 25 2011 14:22 Cambium wrote:
To OP:

Instead of looping through all forms, you can simply refer to liquipedia via its XPath:


var bwlpXPath = "/html/body/table/tbody/tr/td/table[2]/tbody/tr/td[3]/table[4]/tbody/tr/td/form";
node = findXPathNode( bwlpXPath );
node.action = "h__p://wiki.teamliquid.net/starcraft/index.php";


Is this actually any faster than looping through all the forms? There are only like 3 forms on the page, and document.forms should be completely populated as soon as the DOM is ready, shouldn't it? Using XPath goes through the entire html file again, and I'm kinda leery of using it because it's a lot more fragile than just iterating through the forms. (I'm lazy and want to minimize the amount of time I spend maintaining stuff)
Cambium
Profile Blog Joined June 2004
United States16368 Posts
August 25 2011 07:04 GMT
#102
On August 25 2011 15:25 b0lt wrote:
I split up the main script into individual scripts for each feature, I've got them up at http://code.google.com/p/teamliquidbw/source/browse/ now. Also, I polished up WhuazGoodJaggah's stream filter script a bit


Show nested quote +
On August 25 2011 14:22 Cambium wrote:
To OP:

Instead of looping through all forms, you can simply refer to liquipedia via its XPath:


var bwlpXPath = "/html/body/table/tbody/tr/td/table[2]/tbody/tr/td[3]/table[4]/tbody/tr/td/form";
node = findXPathNode( bwlpXPath );
node.action = "h__p://wiki.teamliquid.net/starcraft/index.php";


Is this actually any faster than looping through all the forms? There are only like 3 forms on the page, and document.forms should be completely populated as soon as the DOM is ready, shouldn't it? Using XPath goes through the entire html file again, and I'm kinda leery of using it because it's a lot more fragile than just iterating through the forms. (I'm lazy and want to minimize the amount of time I spend maintaining stuff)


I didn't count the number of forms, but if you say there are three, then there definitely isn't an issue with speed.

You are right about the maintenance though, xpaths are a chore.
When you want something, all the universe conspires in helping you to achieve it.
Sawamura
Profile Blog Joined August 2010
Malaysia7602 Posts
August 25 2011 07:20 GMT
#103
putting your codes on google code is great but some people will not know how to download the script as when they click the link it doesn't allow them to download it instance and they have to right click raw file to download the specific file .
BW/KT Forever R.I.P KT.Violet dearly missed ..
WhuazGoodJaggah
Profile Blog Joined January 2009
Lesotho777 Posts
August 25 2011 08:16 GMT
#104
@b0lt

I made a patch for the streamlist thingy. http://code.google.com/p/teamliquidbw/issues/detail?id=1
The detection of the featured streams node is much better now (no more nextObject.firstChild.firstChild bullshit)
All streams are now filled in 1 array and therefore only 1 loop is needed to separate them into featured and non featured.
And a cosmetic change from . to •
small dicks have great firepower
writer22816
Profile Blog Joined September 2008
United States5775 Posts
August 25 2011 09:10 GMT
#105
Now if only it were possible to have Power Rank, TLFE and R&S back on the main page where they belong
8/4/12 never forget, never forgive.
kuroshiroi
Profile Joined November 2010
3149 Posts
August 25 2011 10:18 GMT
#106
On August 25 2011 18:10 writer22816 wrote:
Now if only it were possible to have Power Rank, TLFE and R&S back on the main page where they belong

It's possible but it would make the script kind of slow, since it'd have to scrape a few pages before it can add those things back in. Not to mention it would take a lot of work.
Fly Jaedong, fly!
Necosarius
Profile Blog Joined September 2009
Sweden4042 Posts
August 26 2011 20:55 GMT
#107
Wow I Have to use this O_O Thank you for doing this <3
quirinus
Profile Blog Joined May 2007
Croatia2489 Posts
August 26 2011 21:06 GMT
#108
On August 25 2011 19:18 kuroshiroi wrote:
Show nested quote +
On August 25 2011 18:10 writer22816 wrote:
Now if only it were possible to have Power Rank, TLFE and R&S back on the main page where they belong

It's possible but it would make the script kind of slow, since it'd have to scrape a few pages before it can add those things back in. Not to mention it would take a lot of work.


It'd be ok if it got PR asynchronous (if I remember correctly, js can handle that), but yea, it's a little bit more work.
All candles lit within him, and there was purity. | First auto-promoted BW LP editor.
PUPATREE
Profile Joined August 2009
340 Posts
August 27 2011 00:16 GMT
#109
That user streams script is fucking wonderful. Thank you.
ㅋㄲㅈㅁ
rift
Profile Blog Joined September 2007
1819 Posts
August 27 2011 23:09 GMT
#110
Can you replicate this script, which removes the SC2 forums entirely from the sidebar? https://chrome.google.com/webstore/detail/fchfgjknoimegjpgekahllojjfilcdno#
quirinus
Profile Blog Joined May 2007
Croatia2489 Posts
August 28 2011 00:14 GMT
#111
On August 28 2011 08:09 rift wrote:
Can you replicate this script, which removes the SC2 forums entirely from the sidebar? https://chrome.google.com/webstore/detail/fchfgjknoimegjpgekahllojjfilcdno#


http://www.teamliquid.net/forum/viewpost.php?post_id=11049981

just add:
remove_section(sc2);
with notepad.
All candles lit within him, and there was purity. | First auto-promoted BW LP editor.
fishbowl
Profile Joined January 2010
United States1575 Posts
August 28 2011 00:40 GMT
#112
You sir, are awesome. Thanks for the script.
Armathai
Profile Joined October 2007
1023 Posts
August 28 2011 06:17 GMT
#113
Can someone which file to edit to get the Replays section under the BW rather than over on the right?

I'd rather have them connected, works better in my mind :D

Looking for ArcticCerebrate formerly from @USEast
WhuazGoodJaggah
Profile Blog Joined January 2009
Lesotho777 Posts
August 28 2011 06:57 GMT
#114
edit the rearrange_forums.user.js

Search for:
/* Move replays to above poll */
move_section(replays, poll);

replace with:
/* Move replays below bw */
move_section(replays, bw);
move_section(bw, replays);
small dicks have great firepower
wishbones
Profile Blog Joined April 2009
Canada2600 Posts
Last Edited: 2011-08-28 07:27:37
August 28 2011 07:15 GMT
#115
is it just me or has the replay section disappeared for anyone else?

On August 28 2011 15:17 Armathai wrote:
Can someone which file to edit to get the Replays section under the BW rather than over on the right?

I'd rather have them connected, works better in my mind :D



oh thanks man it wasnt in the OP. HINT HINT
to me its actually better this way, no more going to the damn bottom of TL and then to the top and back down etc... i hate having to do that in the password entry area on profiles, at least this gives me a break.
joined TL.net in 2006 (aka GMer) - http://www.teamliquid.net/forum/viewmessage.php?topic_id=41944#2
WhuazGoodJaggah
Profile Blog Joined January 2009
Lesotho777 Posts
Last Edited: 2011-08-28 10:15:02
August 28 2011 10:10 GMT
#116
Submited another patch for these scripts: http://code.google.com/p/teamliquidbw/issues/detail?id=2

+ Show Spoiler +
Added another @exclude path (for the ad frame) (threw always an error)
Added SubSections
Added a count argument for nextObject and previousObject


Now it's possible to just remove certain sub sections, like Dota 2 or League of Legends.

You can get this version here or wait until b0lt updates the main repo.
small dicks have great firepower
b0lt
Profile Joined March 2009
United States790 Posts
Last Edited: 2011-08-29 21:53:21
August 29 2011 21:52 GMT
#117
On August 28 2011 19:10 WhuazGoodJaggah wrote:
Submited another patch for these scripts: http://code.google.com/p/teamliquidbw/issues/detail?id=2

+ Show Spoiler +
Added another @exclude path (for the ad frame) (threw always an error)
Added SubSections
Added a count argument for nextObject and previousObject


Now it's possible to just remove certain sub sections, like Dota 2 or League of Legends.

You can get this version here or wait until b0lt updates the main repo.


Merged this, also added power rank scraping while I was at it:

[image loading]
Wolf
Profile Blog Joined April 2010
Korea (South)3290 Posts
August 30 2011 08:16 GMT
#118
Going to try this again tonight most likely. Crossing my fingers!
Commentatorhttp://twitter.com/proxywolf
TL+ Member
kuroshiroi
Profile Joined November 2010
3149 Posts
August 30 2011 16:22 GMT
#119
The re-added PR works great, thanks a bunch

Also, bumpity bump.
Fly Jaedong, fly!
WhuazGoodJaggah
Profile Blog Joined January 2009
Lesotho777 Posts
August 31 2011 06:57 GMT
#120
there is a small bug in the Section code.

+ Show Spoiler +
function Section(id, count) {
this.elements = new Array();

var link = document.getElementById(id);
this.elements.push(link);
for (var x = 0; x < count; x++) {
this.elements.push(nextObject(link, x));
}
}
small dicks have great firepower
XXGeneration
Profile Blog Joined November 2010
United States625 Posts
September 01 2011 00:52 GMT
#121
I can't download the forum switcher; it says something about the script being unlisted.

It might be just me, but I would appreciate any help!
"I was so surprised when I first played StarCraft 2. I couldn't believe that such an easy game exists... I guess the best way to attract people these days is to make things easy and simple." -Midas
NeVeR
Profile Blog Joined January 2009
1352 Posts
September 01 2011 01:30 GMT
#122
Thanks for these. I installed the first three. The "BW Liquipedia" doesn't work for me, and clicking on "Rearrange Forums" just gives me a wall of code.
writer22816
Profile Blog Joined September 2008
United States5775 Posts
September 01 2011 11:14 GMT
#123
On August 30 2011 06:52 b0lt wrote:
Show nested quote +
On August 28 2011 19:10 WhuazGoodJaggah wrote:
Submited another patch for these scripts: http://code.google.com/p/teamliquidbw/issues/detail?id=2

+ Show Spoiler +
Added another @exclude path (for the ad frame) (threw always an error)
Added SubSections
Added a count argument for nextObject and previousObject


Now it's possible to just remove certain sub sections, like Dota 2 or League of Legends.

You can get this version here or wait until b0lt updates the main repo.


Merged this, also added power rank scraping while I was at it:

[image loading]


Holy shit this is amazing! One thing though, the TL Liquipedia script needs to be updated because it defaults to Starcraft 2 now.
8/4/12 never forget, never forgive.
Anackk
Profile Joined October 2009
Croatia1 Post
September 01 2011 11:19 GMT
#124
You sir are a gentleman and a scholar. Thank you.
Spazer
Profile Blog Joined March 2009
Canada8031 Posts
September 01 2011 12:06 GMT
#125
On September 01 2011 10:30 NeVeR wrote:
Thanks for these. I installed the first three. The "BW Liquipedia" doesn't work for me, and clicking on "Rearrange Forums" just gives me a wall of code.

If you use Firefox:
1) Click the greasemonkey icon's dropdown arrow
2) Select "New User Script"
3) Enter in a name. Greasemonkey might insist that you enter in a namespace as well. Just put anything in that box - we'll be deleting that later anyways
4) Your text editor should pop up. Delete all the text.
5) Copy paste all the code from the Google Code site.
6) Save it and you're done!
Liquipedia
kuroshiroi
Profile Joined November 2010
3149 Posts
September 02 2011 10:52 GMT
#126
The power rank scraper isn't updating my comment count any more, does it still work for somebody? I'm using Opera 11.51.
Fly Jaedong, fly!
b0lt
Profile Joined March 2009
United States790 Posts
September 06 2011 00:12 GMT
#127
On September 02 2011 19:52 kuroshiroi wrote:
The power rank scraper isn't updating my comment count any more, does it still work for somebody? I'm using Opera 11.51.


Figured out what was causing this, localStorage stores everything as strings, so it was just appending to the stored time instead of adding to it to figure out whether or not to update.
kuroshiroi
Profile Joined November 2010
3149 Posts
Last Edited: 2011-09-06 12:40:07
September 06 2011 12:38 GMT
#128
On September 06 2011 09:12 b0lt wrote:
Show nested quote +
On September 02 2011 19:52 kuroshiroi wrote:
The power rank scraper isn't updating my comment count any more, does it still work for somebody? I'm using Opera 11.51.


Figured out what was causing this, localStorage stores everything as strings, so it was just appending to the stored time instead of adding to it to figure out whether or not to update.

That would do it, lol. Did you update it?

Edit: Indeed you did, nice, thanks.
Fly Jaedong, fly!
soujiro_
Profile Joined June 2010
Uruguay5195 Posts
September 12 2011 00:04 GMT
#129
lil bump just installed it again this time on opera, id love to have the news at the bottom and tsl removed =)
ace hwaiting!!
darkmetal505
Profile Blog Joined March 2007
United States639 Posts
September 12 2011 01:31 GMT
#130
This is a godsend. Thank you!
Kyuukyuu
Profile Blog Joined January 2009
Canada6263 Posts
September 12 2011 02:43 GMT
#131
This just stopped working for me, out of the blue it seems o_o. Did it have to do with the newest FFox update or am I missing something?
Thratur
Profile Blog Joined June 2008
Canada917 Posts
Last Edited: 2011-09-12 03:13:56
September 12 2011 03:11 GMT
#132
Also stopped working out of the blue for me using Chrome...

EDIT : After updating to the newest version, only the "rearrange forums" doesn't work anymore.
Hyde
Profile Blog Joined November 2007
Australia14568 Posts
September 12 2011 03:27 GMT
#133
On September 12 2011 09:04 soujiro_ wrote:
lil bump just installed it again this time on opera, id love to have the news at the bottom and tsl removed =)

Looks like TSL got removed and put up to the top bar.

They've also gotten around to adding an option to search BW in liquipedia now so that's cool, still need the script though to keep it on bw as a default.
Because when you left, Brood War was all spotlights and titans. Now, with the death of the big leagues, Brood War has moved to the basements and carparks. Now, Brood War is unlicensed brawls, lost teeth, and bloody fights for fistfulls of money - SirJolt
a176
Profile Blog Joined August 2009
Canada6688 Posts
September 12 2011 03:37 GMT
#134
On September 12 2011 12:11 Thratur wrote:
Also stopped working out of the blue for me using Chrome...

EDIT : After updating to the newest version, only the "rearrange forums" doesn't work anymore.


same issue here
starleague forever
writer22816
Profile Blog Joined September 2008
United States5775 Posts
Last Edited: 2011-09-12 04:54:54
September 12 2011 04:53 GMT
#135
Oh yeah same issue here on Opera 11.51. Odd as it was working perfectly fine a few hours ago. Perhaps this is due to the TL web page being updated (TSL is now moved to the top bar).
8/4/12 never forget, never forgive.
Pippah
Profile Joined January 2010
Denmark353 Posts
September 12 2011 05:20 GMT
#136
Very nice! Thanks.

Everything seems to work, however I still dont see the powerrank in the bar to the right, am I supposed to?
Tomken
Profile Joined January 2010
Norway1144 Posts
September 12 2011 05:40 GMT
#137
On September 12 2011 12:11 Thratur wrote:
Also stopped working out of the blue for me using Chrome...

EDIT : After updating to the newest version, only the "rearrange forums" doesn't work anymore.

Same + liquipedia.
MBCGame HERO FIGHTING!!!~
b0lt
Profile Joined March 2009
United States790 Posts
September 12 2011 07:14 GMT
#138
Fixed
prototype.
Profile Blog Joined July 2009
Canada4200 Posts
Last Edited: 2011-09-12 08:29:40
September 12 2011 08:27 GMT
#139
the code for rearranging forum sections doesn't move BW above SC2 anymore?
( ・´ー・`)
XsebT
Profile Blog Joined June 2009
Denmark2980 Posts
September 12 2011 09:54 GMT
#140
On September 12 2011 16:14 b0lt wrote:
Fixed

Awesome! Thank you so much for keeping it updated!
화이팅
kuroshiroi
Profile Joined November 2010
3149 Posts
September 12 2011 09:55 GMT
#141
On September 12 2011 16:14 b0lt wrote:
Fixed

Thanks for the quick fix!
Fly Jaedong, fly!
a176
Profile Blog Joined August 2009
Canada6688 Posts
September 12 2011 13:11 GMT
#142
yay! thanks!
starleague forever
soujiro_
Profile Joined June 2010
Uruguay5195 Posts
September 12 2011 13:15 GMT
#143
wow thanks for keeping this updated =D
ace hwaiting!!
Sawamura
Profile Blog Joined August 2010
Malaysia7602 Posts
September 12 2011 13:46 GMT
#144
Thanks for the update bolt ..
BW/KT Forever R.I.P KT.Violet dearly missed ..
Prof. Protoss
Profile Blog Joined October 2007
Germany744 Posts
September 12 2011 14:40 GMT
#145
I just discovered this - very nice!

Thanks a ton!
Don't mess the fess!
Yurie
Profile Blog Joined August 2010
11800 Posts
Last Edited: 2011-09-12 14:51:06
September 12 2011 14:47 GMT
#146
Is it possible to remove the Diablo 3 section?
Tomken
Profile Joined January 2010
Norway1144 Posts
Last Edited: 2011-09-12 15:09:54
September 12 2011 15:07 GMT
#147
On September 12 2011 23:47 Yurie wrote:
Is it possible to remove the Diablo 3 section?

Just hide it yourself?

Edit: or u mean the streaming?

Edit: TT the Rearrenge Forum doesn't work for me :/
MBCGame HERO FIGHTING!!!~
Talia
Profile Joined April 2010
Germany64 Posts
September 12 2011 18:21 GMT
#148
I love you for this!
Even though it makes me kinda sad to only see like 3 BW streams...
Pandaaa
Cri du Chat
Profile Joined February 2010
Germany606 Posts
September 12 2011 18:51 GMT
#149
On September 12 2011 23:47 Yurie wrote:
Is it possible to remove the Diablo 3 section?


I did it like this:

First copy that in the section with all the var-stuff

var diablo_3 = new SubSection(64);

Then copy this where all the remove_sections are

remove_section(diablo_3);

Works for me
kangur
Profile Joined November 2009
29 Posts
September 12 2011 20:01 GMT
#150
Can you add it to http://userscripts.org/ ?
Bisu-Fan
Profile Joined January 2010
Russian Federation3329 Posts
September 13 2011 04:01 GMT
#151
Thanks so much~!!! I didn't realize how much I missed having power rankings on the side until I got them back again and I was like, O.o ;( "how much I have missed thee"
The Revolutionist Shall Rise Again! No. 1 Kim Taek Yong Fan 어헣↗ GO JAEDONG!!!!!!! GO ACE!!! 태연 <3 윤아 <3 승연 <3
jpak
Profile Blog Joined October 2009
United States5045 Posts
September 15 2011 14:19 GMT
#152
On September 13 2011 13:01 Bisu-Fan wrote:
Thanks so much~!!! I didn't realize how much I missed having power rankings on the side until I got them back again and I was like, O.o ;( "how much I have missed thee"


Feel the same here. The part of me that died was revived with these scripts. Thanks a lot.
CJ Entusman #50! #1 클템 fan TL!
writer22816
Profile Blog Joined September 2008
United States5775 Posts
Last Edited: 2011-09-16 09:22:46
September 16 2011 09:20 GMT
#153
I feel its worth bumping this to because TL has included the first BW related poll in over a year, and the current userscripts remove the poll section entirely.

Go into the user script code and comment out the line that declares

var poll = new Section("nav_poll", 1);

Have fun voting!
8/4/12 never forget, never forgive.
soujiro_
Profile Joined June 2010
Uruguay5195 Posts
September 16 2011 15:11 GMT
#154
the bw liquipedia search script its broken as it goes to sc2 liquipedia =\
ace hwaiting!!
Simplistik
Profile Blog Joined November 2007
2003 Posts
September 16 2011 17:02 GMT
#155
After messing around a bit, I just can't get the forum rearrange script to work. As far as I'm concerned it doesn't do anything. The other scripts work fine. Am I silly?
Dear BW Gods, I know it's not autumn (in the Northern hemisphere), but please have mercy on Protoss.
b0lt
Profile Joined March 2009
United States790 Posts
September 16 2011 18:20 GMT
#156
On September 17 2011 02:02 Simplistik wrote:
After messing around a bit, I just can't get the forum rearrange script to work. As far as I'm concerned it doesn't do anything. The other scripts work fine. Am I silly?


What browser/version/plugin version are you using? Open up the javascript console (ctrl shift j in chrome, ctrl shift k in firefox, something in opera), clear the messages, then refresh teamliquid. Do any errors show up?
Simplistik
Profile Blog Joined November 2007
2003 Posts
September 16 2011 21:18 GMT
#157
Phew, thanks for the speedy response and thanks for the plugins.

I'm using Firefox 3.6.22 and the 2.7a version of the plugin.

The error console returns two errors:
Line 77: Component is not available
Line 284: n is null

If it's to do with Firefox 3 then I guess I could finally upgrade. (Do they fonts render correctly in FF 4 now?)
Dear BW Gods, I know it's not autumn (in the Northern hemisphere), but please have mercy on Protoss.
b0lt
Profile Joined March 2009
United States790 Posts
September 17 2011 11:50 GMT
#158
On September 17 2011 06:18 Simplistik wrote:
Phew, thanks for the speedy response and thanks for the plugins.

I'm using Firefox 3.6.22 and the 2.7a version of the plugin.

The error console returns two errors:
Line 77: Component is not available
Line 284: n is null

If it's to do with Firefox 3 then I guess I could finally upgrade. (Do they fonts render correctly in FF 4 now?)


Do you have an old version of the script installed alongside the current one? I'm not sure what would be causing this, it works fine for me on a fresh install of the the latest version of firefox/greasemonkey.
Kiett
Profile Blog Joined March 2011
United States7639 Posts
November 01 2011 10:01 GMT
#159
Will there be an update to this to go along with the TL site changes? I don't want to lose power rank in the sidebar
Writer:o
chaosTheory_14cc
Profile Blog Joined December 2010
Canada1270 Posts
Last Edited: 2011-11-01 19:01:44
November 01 2011 18:59 GMT
#160
On November 01 2011 19:01 seraphe wrote:
Will there be an update to this to go along with the TL site changes? I don't want to lose power rank in the sidebar

Yeah, definitely want to keep power rank, although the rest of the sidebar is pretty great. The rearrange forums script needs to be updated the fastest imo, since being able to get rid of the sc2 section will allow for a nearly BW only TL interface.

edit: the power rank/store swapping script on the main toolbar still seems to work fine.
4vvhiplash7
Profile Joined December 2010
South Africa392 Posts
November 01 2011 19:20 GMT
#161
Thanks for this bolt. Random question, but could you make a userscript for iPad? I mostly go on TL from my iPad and it would be nice if I could use the same userscript. I.e. can you make one for 'safari'?

Thanks again!
rift
Profile Blog Joined September 2007
1819 Posts
Last Edited: 2011-11-02 04:55:14
November 01 2011 19:23 GMT
#162
repeated post
WhuazGoodJaggah
Profile Blog Joined January 2009
Lesotho777 Posts
November 01 2011 19:50 GMT
#163
On November 02 2011 04:23 rift wrote:
https://chrome.google.com/webstore/detail/fchfgjknoimegjpgekahllojjfilcdno#

This Chrome extension makes the entire SC2 section disappear on the left sidebar. Could you do this in the script for Firefox?


read the thread, this is already done.
small dicks have great firepower
Spazer
Profile Blog Joined March 2009
Canada8031 Posts
Last Edited: 2011-11-03 01:13:53
November 02 2011 03:30 GMT
#164
On November 02 2011 03:59 chaosTheory_14cc wrote:
Show nested quote +
On November 01 2011 19:01 seraphe wrote:
Will there be an update to this to go along with the TL site changes? I don't want to lose power rank in the sidebar

Yeah, definitely want to keep power rank, although the rest of the sidebar is pretty great. The rearrange forums script needs to be updated the fastest imo, since being able to get rid of the sc2 section will allow for a nearly BW only TL interface.

edit: the power rank/store swapping script on the main toolbar still seems to work fine.

You can fix all this stuff yourself since the main problem here is that polls is now gone.

Open the script, and delete
var poll = new Section("nav_poll", 1);


Moving the replay section:
move_section(replays, poll);

This obviously will not work anymore. Replace "poll" with "liquipedia" or something if you want to move it. Otherwise delete the line.

Similarly, power rank can be readded by changing
/* Readd the power rank section */
prepend_section(pr, poll);

Again, just change "poll" to another section name like "liquipedia"
Liquipedia
chaosTheory_14cc
Profile Blog Joined December 2010
Canada1270 Posts
November 02 2011 13:02 GMT
#165
On November 02 2011 12:30 Spazer wrote:
Show nested quote +
On November 02 2011 03:59 chaosTheory_14cc wrote:
On November 01 2011 19:01 seraphe wrote:
Will there be an update to this to go along with the TL site changes? I don't want to lose power rank in the sidebar

Yeah, definitely want to keep power rank, although the rest of the sidebar is pretty great. The rearrange forums script needs to be updated the fastest imo, since being able to get rid of the sc2 section will allow for a nearly BW only TL interface.

edit: the power rank/store swapping script on the main toolbar still seems to work fine.

You can fix all this stuff yourself since the main problem here is that polls is now gone.

Open the script, and delete
var poll = new Section("nav_poll", 1);


Moving the replay section:
move_section(replays, poll);

This obviously will not work anymore. Replace "poll" with "liquipedia" or something if you want to move it.

Similarly, power rank can be readded by changing
/* Readd the power rank section */
prepend_section(pr, poll);

Again, just change "poll" to another section name like "liquipedia"

Thanks a bunch, I'm pretty bad when it comes to this stuff.

I'll try it out when I get home.
JIJIyO
Profile Blog Joined January 2009
Canada1957 Posts
November 02 2011 20:48 GMT
#166
The rearrange forum script doesn't seem to work for me. I'm on Firefox using greasemonkey. I'm pretty bad at this stuff, so tell me if I did it wrong. I just left clicked the rearrange forums script on the 1st pg and then installed it. That should make it work, right?
KT_Violet
Barbarne
Profile Joined August 2007
Sweden458 Posts
November 02 2011 23:22 GMT
#167
On November 03 2011 05:48 JIJIyO wrote:
The rearrange forum script doesn't seem to work for me. I'm on Firefox using greasemonkey. I'm pretty bad at this stuff, so tell me if I did it wrong. I just left clicked the rearrange forums script on the 1st pg and then installed it. That should make it work, right?


It stopped working for me too, so I guess it's something with the new layout that's causing that.

Hoping for a fix for the rearranage forums script and some way to get power rank back in the sidebar : )
Spazer
Profile Blog Joined March 2009
Canada8031 Posts
November 03 2011 01:12 GMT
#168
The script is currently broken, so you have to edit it to make it work.

To edit a script:

Firefox button > Add ons

Click on the "userscripts" button on the left sidebar. Right click the rearrange forums script and choose edit.

All the necessary changes are detailed in my last post.
Liquipedia
kangur
Profile Joined November 2009
29 Posts
Last Edited: 2011-11-29 18:44:47
November 29 2011 18:39 GMT
#169
Normal
Please log in or register to reply.
Live Events Refresh
PiGosaur Monday
00:00
#38
PiGStarcraft754
rockletztv 33
Liquipedia
[ Submit Event ]
Live Streams
Refresh
StarCraft 2
PiGStarcraft754
RuFF_SC2 133
Livibee 82
StarCraft: Brood War
Icarus 10
Noble 6
Dota 2
monkeys_forever691
League of Legends
JimRising 1312
Counter-Strike
summit1g9059
PGG 45
Super Smash Bros
hungrybox611
Heroes of the Storm
Khaldor108
Other Games
tarik_tv7054
Fnx 3312
shahzam666
WinterStarcraft205
Maynarde172
CosmosSc2 19
Organizations
Other Games
gamesdonequick1368
StarCraft 2
Blizzard YouTube
StarCraft: Brood War
BSLTrovo
sctven
[ Show 16 non-featured ]
StarCraft 2
• Hupsaiya 120
• practicex 7
• AfreecaTV YouTube
• sooper7s
• intothetv
• Kozan
• IndyKCrew
• LaughNgamezSOOP
• Migwel
StarCraft: Brood War
• Azhi_Dahaki164
• STPLYoutube
• ZZZeroYoutube
• BSLYoutube
League of Legends
• Doublelift4430
• masondota2596
Other Games
• Scarra1586
Upcoming Events
Replay Cast
20h 27m
The PondCast
1d 6h
RSL Revival
1d 6h
ByuN vs Classic
Clem vs Cham
WardiTV European League
1d 12h
Replay Cast
1d 20h
RSL Revival
2 days
herO vs SHIN
Reynor vs Cure
WardiTV European League
2 days
FEL
2 days
Korean StarCraft League
2 days
CranKy Ducklings
3 days
[ Show More ]
RSL Revival
3 days
FEL
3 days
Sparkling Tuna Cup
4 days
RSL Revival
4 days
FEL
4 days
BSL: ProLeague
4 days
Dewalt vs Bonyth
Replay Cast
5 days
Replay Cast
6 days
Liquipedia Results

Completed

Proleague 2025-06-28
HSC XXVII
Heroes 10 EU

Ongoing

JPL Season 2
BSL 2v2 Season 3
BSL Season 20
Acropolis #3
KCM Race Survival 2025 Season 2
CSL 17: 2025 SUMMER
Copa Latinoamericana 4
Championship of Russia 2025
RSL Revival: Season 1
Murky Cup #2
BLAST.tv Austin Major 2025
ESL Impact League Season 7
IEM Dallas 2025
PGL Astana 2025
Asian Champions League '25
BLAST Rivals Spring 2025
MESA Nomadic Masters
CCT Season 2 Global Finals
IEM Melbourne 2025
YaLLa Compass Qatar 2025

Upcoming

CSLPRO Last Chance 2025
CSLPRO Chat StarLAN 3
K-Championship
uThermal 2v2 Main Event
SEL Season 2 Championship
FEL Cracov 2025
Esports World Cup 2025
StarSeries Fall 2025
FISSURE Playground #2
BLAST Open Fall 2025
BLAST Open Fall Qual
Esports World Cup 2025
BLAST Bounty Fall 2025
BLAST Bounty Fall Qual
IEM Cologne 2025
FISSURE Playground #1
TLPD

1. ByuN
2. TY
3. Dark
4. Solar
5. Stats
6. Nerchio
7. sOs
8. soO
9. INnoVation
10. Elazer
1. Rain
2. Flash
3. EffOrt
4. Last
5. Bisu
6. Soulkey
7. Mini
8. Sharp
Sidebar Settings...

Advertising | Privacy Policy | Terms Of Use | Contact Us

Original banner artwork: Jim Warren
The contents of this webpage are copyright © 2025 TLnet. All Rights Reserved.