#!/usr/bin/perl -w
use strict;
# sobad
my $content = `curl -s http://www.failheap-challenge.com/forum.php`;
my $wanted = lc($ARGV[0]) || 'members';
if($content =~ /<div[^>]+id="wgo_stats".*?>(.*?)<\/div>/msi){
my $statblock = $1;
while($statblock =~ s/<dt>(.*?)<\
/dt
>\
s*<dd>(.*?)<\
/dd
>//msi
){
my $name = $1;
my $val = $2;
$val =~ s/\D//g;
$values{lc($name)} = $val;
}
}
print "Members: " . $values{$wanted} . " | members=" . $values{$wanted} || print 0;
Replies to Untitled
{"html5":"htmlmixed","css":"css","javascript":"javascript","php":"php","python":"python","ruby":"ruby","lua":"text\/x-lua","bash":"text\/x-sh","go":"text\/x-go","c":"text\/x-csrc","cpp":"text\/x-c++src","diff":"diff","latex":"stex","sql":"mysql","xml":"xml","c_loadrunner":"text\/x-csrc","c_mac":"text\/x-csrc","coffeescript":"text\/x-coffeescript","csharp":"text\/x-csharp","ecmascript":"javascript","groovy":"text\/x-groovy","haskell":"text\/x-haskell","html4strict":"htmlmixed","java":"text\/x-java","java5":"text\/x-java","jquery":"javascript","mysql":"mysql","pascal":"text\/x-pascal","perl":"perl","perl6":"perl","plsql":"plsql","properties":"text\/x-properties","scheme":"text\/x-scheme","vb":"text\/vbscript","vbnet":"text\/vbscript","verilog":"text\/x-verilog","yaml":"text\/x-yaml"}