• Log InLog In
  • Register
Liquid`
Team Liquid Liquipedia
EST 13:07
CET 19:07
KST 03:07
  • 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
Rongyi Cup S3 - Preview & Info3herO wins SC2 All-Star Invitational14SC2 All-Star Invitational: Tournament Preview5RSL Revival - 2025 Season Finals Preview8RSL Season 3 - Playoffs Preview0
Community News
Weekly Cups (Jan 19-25): Bunny, Trigger, MaxPax win3Weekly Cups (Jan 12-18): herO, MaxPax, Solar win0BSL Season 2025 - Full Overview and Conclusion8Weekly Cups (Jan 5-11): Clem wins big offline, Trigger upsets4$21,000 Rongyi Cup Season 3 announced (Jan 22-Feb 7)38
StarCraft 2
General
StarCraft 2 not at the Esports World Cup 2026 Weekly Cups (Jan 19-25): Bunny, Trigger, MaxPax win Oliveira Would Have Returned If EWC Continued herO wins SC2 All-Star Invitational PhD study /w SC2 - help with a survey!
Tourneys
$21,000 Rongyi Cup Season 3 announced (Jan 22-Feb 7) OSC Season 13 World Championship $70 Prize Pool Ladder Legends Academy Weekly Open! SC2 All-Star Invitational: Jan 17-18 Sparkling Tuna Cup - Weekly Open Tournament
Strategy
Simple Questions Simple Answers
Custom Maps
[A] Starcraft Sound Mod
External Content
Mutation # 510 Safety Violation Mutation # 509 Doomsday Report Mutation # 508 Violent Night Mutation # 507 Well Trained
Brood War
General
Potential ASL qualifier breakthroughs? BW General Discussion BGH Auto Balance -> http://bghmmr.eu/ Bleak Future After Failed ProGaming Career [ASL21] Potential Map Candidates
Tourneys
[Megathread] Daily Proleagues Small VOD Thread 2.0 Azhi's Colosseum - Season 2 [BSL21] Non-Korean Championship - Starts Jan 10
Strategy
Simple Questions, Simple Answers Zealot bombing is no longer popular? Current Meta Soma's 9 hatch build from ASL Game 2
Other Games
General Games
Battle Aces/David Kim RTS Megathread Path of Exile Nintendo Switch Thread Mobile Legends: Bang Bang 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
Deck construction bug Heroes of StarCraft mini-set
TL Mafia
Vanilla Mini Mafia Mafia Game Mode Feedback/Ideas
Community
General
US Politics Mega-thread Russo-Ukrainian War Thread YouTube Thread Canadian Politics Mega-thread European Politico-economics QA Mega-thread
Fan Clubs
The herO Fan Club! The IdrA Fan Club
Media & Entertainment
Anime Discussion Thread [Manga] One Piece
Sports
2024 - 2026 Football Thread
World Cup 2022
Tech Support
Computer Build, Upgrade & Buying Resource Thread
TL Community
The Automated Ban List
Blogs
How Esports Advertising Shap…
TrAiDoS
My 2025 Magic: The Gathering…
DARKING
Life Update and thoughts.
FuDDx
How do archons sleep?
8882
James Bond movies ranking - pa…
Topin
Customize Sidebar...

Website Feedback

Closed Threads



Active: 1689 users

TL BW Userscript - Page 6

Forum Index > BW General
Post a Reply
Prev 1 4 5 6 7 8 9 Next All
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
Prev 1 4 5 6 7 8 9 Next All
Please log in or register to reply.
Live Events Refresh
Next event in 17h 53m
[ Submit Event ]
Live Streams
Refresh
StarCraft 2
SpeCial 136
ProTech135
JuggernautJason133
BRAT_OK 113
MindelVK 38
StarCraft: Brood War
Rain 7643
Soulkey 892
Larva 793
Mini 735
EffOrt 500
BeSt 185
Hyuk 127
Dewaltoss 102
ggaemo 94
Snow 91
[ Show more ]
Shuttle 47
scan(afreeca) 21
Rock 12
Dota 2
Dendi770
League of Legends
C9.Mang0102
Counter-Strike
fl0m4078
kRYSTAL_17
Heroes of the Storm
Liquid`Hasu139
Other Games
gofns9076
Grubby3036
FrodaN1638
hiko776
QueenE276
crisheroes249
ArmadaUGS110
KnowMe97
Mew2King96
ToD79
Organizations
StarCraft 2
angryscii 33
Blizzard YouTube
StarCraft: Brood War
BSLTrovo
sctven
[ Show 17 non-featured ]
StarCraft 2
• poizon28 79
• Adnapsc2 5
• intothetv
• IndyKCrew
• sooper7s
• AfreecaTV YouTube
• Migwel
• LaughNgamezSOOP
• Kozan
StarCraft: Brood War
• STPLYoutube
• ZZZeroYoutube
• BSLYoutube
Dota 2
• WagamamaTV386
League of Legends
• Nemesis2388
• TFBlade1709
• imaqtpie324
• Shiphtur227
Upcoming Events
HomeStory Cup
17h 53m
Korean StarCraft League
1d 8h
HomeStory Cup
1d 17h
Replay Cast
2 days
HomeStory Cup
2 days
Replay Cast
3 days
Replay Cast
4 days
Wardi Open
4 days
WardiTV Invitational
5 days
The PondCast
6 days
[ Show More ]
WardiTV Invitational
6 days
Liquipedia Results

Completed

Proleague 2026-01-28
OSC Championship Season 13
Underdog Cup #3

Ongoing

CSL 2025 WINTER (S19)
KCM Race Survival 2026 Season 1
Acropolis #4 - TS4
Rongyi Cup S3
IEM Kraków 2026
BLAST Bounty Winter 2026
BLAST Bounty Winter Qual
eXTREMESLAND 2025
SL Budapest Major 2025
ESL Impact League Season 8
BLAST Rivals Fall 2025

Upcoming

Escore Tournament S1: W6
Escore Tournament S1: W7
Acropolis #4
IPSL Spring 2026
uThermal 2v2 2026 Main Event
Bellum Gens Elite Stara Zagora 2026
LiuLi Cup: 2025 Grand Finals
HSC XXVIII
Nations Cup 2026
IEM Rio 2026
PGL Bucharest 2026
Stake Ranked Episode 1
BLAST Open Spring 2026
ESL Pro League Season 23
ESL Pro League Season 23
PGL Cluj-Napoca 2026
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 © 2026 TLnet. All Rights Reserved.