• Log InLog In
  • Register
Liquid`
Team Liquid Liquipedia
EST 09:27
CET 15:27
KST 23:27
  • 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 - RO16 Preview3herO wins SC2 All-Star Invitational12SC2 All-Star Invitational: Tournament Preview5RSL Revival - 2025 Season Finals Preview8RSL Season 3 - Playoffs Preview0
Community News
Weekly 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)23Weekly Cups (Dec 29-Jan 4): Protoss rolls, 2v2 returns7
StarCraft 2
General
PhD study /w SC2 - help with a survey! herO wins SC2 All-Star Invitational Oliveira Would Have Returned If EWC Continued StarCraft 2 not at the Esports World Cup 2026 [Short Story] The Last GSL
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 # 509 Doomsday Report Mutation # 508 Violent Night Mutation # 507 Well Trained Mutation # 506 Warp Zone
Brood War
General
[ASL21] Potential Map Candidates Gypsy to Korea BGH Auto Balance -> http://bghmmr.eu/ Fantasy's Q&A video BW General Discussion
Tourneys
[Megathread] Daily Proleagues Azhi's Colosseum - Season 2 Small VOD Thread 2.0 [BSL21] Non-Korean Championship - Starts Jan 10
Strategy
Current Meta Simple Questions, Simple Answers Soma's 9 hatch build from ASL Game 2 Game Theory for Starcraft
Other Games
General Games
Nintendo Switch Thread Battle Aces/David Kim RTS Megathread Stormgate/Frost Giant Megathread Beyond All Reason Awesome Games Done Quick 2026!
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 European Politico-economics QA Mega-thread Canadian Politics Mega-thread NASA and the Private Sector
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: 2470 users

[PHP] Chat log link filter

Blogs > quirinus
Post a Reply
quirinus
Profile Blog Joined May 2007
Croatia2489 Posts
Last Edited: 2013-06-08 07:53:03
June 08 2013 07:29 GMT
#1
This PHP script allows you to load a file and it reads line by line to filters out links. I decided to post it here just in case someone needs something like this.

This was something I wanted to make for a long time, but didn't have the time and motivation to do it until now.
I made this specifically to log links from RollPlay live chat so I can watch it in peace instead of having to click every link to see it before it's lost (there's a lot of hilarious pictures). I'm archiving the pictures and links for the nostalgia value and to help people who can't watch live to have some taste of the gems and atmosphere from the chat.
If anyone wants to help log itmejp's channel during RollPlay that would be awesome in case I get disconnected or unable to do it. (Later we could even get complete VODs+chat with that; yes, I know someone else is doing it already - the more the merrier.)

I probably won't be updating this script for a while, if ever.



Features:
  • It will show the time when the link first appeared; next to it is the number of times it was written in chat.
  • It allows you to copy all the links at once (without timestamps) and you can click on them to check them.
  • For longer chat sessions, I suggest turning on Show sessions when loading a log file so you can see when disconnects happen.
  • If there's some timezone/time mismatch, you can manually write your timezone.

Screenshot:

[image loading]


Code:

Pastebin raw text link

It's very ineffective, not optimized, very badly structured and not commented, but it does what I need it to, without any problem.



Settings:

Note that this script was written mostly with mIRC in mind. I assume other IRC programs behave similarly, so you can use them as well if they can format log files similarly. The .log file text formatting I used was:
+ Show Spoiler +
It assumes that the message format is: [time] <nickname> Message
Message time stamps should be Fri, 07 Jun 2013 13:45:54 +0200, but I think others would work as well, especially if sessions are formatted in the same way.
Session start should be indicated by Session Start: in the line, followed by a time stamp like above.
Session end should use Session Close:, followed by a time stamp as well.


mIRC settings that will allow you to log and filter the chat links:
+ Show Spoiler +
Tools -> Options -> IRC -> Logging -> [checked] Timestamp logs: [ddd, dd mmm yyyy HH:nn:ss zz]

Tools -> Options -> Connect -> Nickname -> your_twitch_account_name (case sensitive)
Tools -> Options -> Connect -> Alternative-> your_twitch_account_name
Tools -> Options -> Connect -> Servers -> Add:
Description: Twitch.tv
IRC Server: your_account_name.jtvirc.com
Port: 6667
Group: Twitch.tv
Password: your_account_password

Then select it on the list and click the Select button.
Click Connect. (in the future, you can connect by clicking the thunderbolt button on the top left)

Once connected type /j channel_name to join a channel and stay in to keep logging it.

If you can't connect to the server (happens often), just keep trying, or add another server:
Description: Twitch.tv IP
IRC Server: 199.9.250.229
Port: 6667
Group: Twitch.tv
Password: your_account_password

And follow the same steps.

My log file folder is in: C:\Users\My_Name\AppData\Roaming\mIRC
You can find yours by going to: Tools -> Options -> IRC -> Logging -> Logs and buffer saves folder button.

  • If you're renaming the file, don't forget to change the name in the line $self_path = "links.php"; at the start as well.
  • If you want, you can choose a default timezone by un-commenting the line that contains $timezone_override and writing your timezone instead of Europe/Zagreb. (You can see the timezones list here.)



I suggest clearing the log every time you have a new link-recording-session so things don't get mixed up or just manually copy the sessions you need to a new file/folder - it's not necessary, but it will probably help you a lot with big logs.

Have fun!

All candles lit within him, and there was purity. | First auto-promoted BW LP editor.
quirinus
Profile Blog Joined May 2007
Croatia2489 Posts
Last Edited: 2013-06-11 07:04:48
June 08 2013 07:33 GMT
#2
I'm not sure if this is supposed to be posted in blogs or normal forum, so I decided to post it here as it's less obtrusive and belongs to a small niche.

edit: eh seems TL removes backslashes, I guess I'll link the code from somewhere else, brb.
edit2: fixed a few mistakes, should work as intended now
All candles lit within him, and there was purity. | First auto-promoted BW LP editor.
Please log in or register to reply.
Live Events Refresh
uThermal 2v2 Circuit
12:00
Bonus Cup #2
uThermal931
IndyStarCraft 404
SteadfastSC175
Liquipedia
[ Submit Event ]
Live Streams
Refresh
StarCraft 2
uThermal 931
IndyStarCraft 404
Harstem 389
SteadfastSC 175
Rex 132
ProTech57
StarCraft: Brood War
Rain 4476
Sea 3260
Shuttle 1837
Jaedong 1241
EffOrt 668
Larva 629
BeSt 597
Stork 597
Mini 498
hero 476
[ Show more ]
Hyuk 447
GuemChi 428
ZerO 364
Light 339
actioN 321
firebathero 318
ggaemo 289
Rush 221
Killer 163
Barracks 149
Hyun 114
Mong 104
Soulkey 93
Mind 82
Sharp 73
Sea.KH 73
Hm[arnc] 72
Yoon 38
Shinee 37
Backho 28
sorry 26
Free 24
GoRush 21
Noble 20
Shine 17
soO 16
zelot 14
HiyA 14
Terrorterran 13
Rock 9
Icarus 9
JulyZerg 7
Dota 2
Gorgc3358
singsing2261
qojqva2192
420jenkins1083
syndereN297
Counter-Strike
kennyS3331
zeus1577
edward139
Super Smash Bros
Mew2King52
Heroes of the Storm
Khaldor350
Other Games
Liquid`RaSZi1428
B2W.Neo1270
ToD159
XaKoH 127
DeMusliM51
ZerO(Twitch)25
Organizations
StarCraft: Brood War
Kim Chul Min (afreeca) 12
StarCraft 2
Blizzard YouTube
StarCraft: Brood War
BSLTrovo
sctven
[ Show 12 non-featured ]
StarCraft 2
• AfreecaTV YouTube
• intothetv
• Kozan
• IndyKCrew
• LaughNgamezSOOP
• Migwel
• sooper7s
StarCraft: Brood War
• Michael_bg 6
• BSLYoutube
• STPLYoutube
• ZZZeroYoutube
League of Legends
• Jankos3456
Upcoming Events
BSL 21
33m
Replay Cast
9h 33m
Wardi Open
23h 33m
Monday Night Weeklies
1d 2h
OSC
1d 9h
Replay Cast
1d 18h
WardiTV Invitational
1d 23h
Replay Cast
2 days
WardiTV Invitational
2 days
The PondCast
3 days
[ Show More ]
HomeStory Cup
4 days
Korean StarCraft League
5 days
HomeStory Cup
5 days
Replay Cast
6 days
HomeStory Cup
6 days
Liquipedia Results

Completed

Proleague 2026-01-24
OSC Championship Season 13
Tektek Cup #1

Ongoing

C-Race Season 1
BSL 21 Non-Korean Championship
CSL 2025 WINTER (S19)
KCM Race Survival 2026 Season 1
Acropolis #4 - TS4
Rongyi Cup S3
Underdog Cup #3
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
HSC XXVIII
Nations Cup 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
IEM Kraków 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.