// var socket=io('http://localhost:8080'); var socket=io('http://202.124.184.250:8080');
jQuery( document ).ready(function() { console.log( "ready" ); var prev_bat_team = 0;
socket.on('message',function (message) { message = JSON.parse(message); console.log(message); if( message.data.cric.commentary){ jQuery('#cmt_wrap').prepend('
'+message.data.cric.commentary.event+'
'+message.data.cric.commentary.comment+'
'); } if(message.data.cric.match){ console.log(message.data.cric.match.teams_1_inn2_r[0]); function ove(balls) { var overs = 0; if(balls %6 == 0){ overs = balls/6; }else{ overs = parseInt(balls/6)+"."+(+balls - +parseInt(balls/6)*6); } console.log(overs); return overs; }
if(!message.data.cric.match.teams_1_inn2_r[0]){
jQuery('#score_1_'+message.data.cric.match.teams_1_r[0]['id']).html(message.data.cric.match.teams_1_r[0]['score'] + " / " + message.data.cric.match.teams_1_r[0]['wkts']); jQuery('#over_1_'+message.data.cric.match.teams_1_r[0]['id']).html("("+ove(message.data.cric.match.teams_1_r[0]['balls'])+" overs)"); }else { jQuery('#score_1_'+message.data.cric.match.teams_1_r[0]['id']).html(message.data.cric.match.teams_1_r[0]['score'] + " / " + message.data.cric.match.teams_1_r[0]['wkts']+" & "+message.data.cric.match.teams_1_inn2_r[0]['score']+" / "+message.data.cric.match.teams_1_inn2_r[0]['wkts']); jQuery('#over_1_'+message.data.cric.match.teams_1_r[0]['id']).html("("+ove(message.data.cric.match.teams_1_inn2_r[0]['balls'])+" overs)"); } if(!message.data.cric.match.teams_2_inn2_r[0]){
jQuery('#score_2_'+message.data.cric.match.teams_2_r[0]['id']).html(message.data.cric.match.teams_2_r[0]['score'] + " / " + message.data.cric.match.teams_2_r[0]['wkts']); jQuery('#over_2_'+message.data.cric.match.teams_2_r[0]['id']).html("("+ove(message.data.cric.match.teams_2_r[0]['balls'])+" overs)"); }else { jQuery('#score_2_'+message.data.cric.match.teams_2_r[0]['id']).html(message.data.cric.match.teams_2_r[0]['score'] + " / " + message.data.cric.match.teams_2_r[0]['wkts']+" & "+message.data.cric.match.teams_2_inn2_r[0]['score']+" / "+message.data.cric.match.teams_2_inn2_r[0]['wkts']); jQuery('#over_2_'+message.data.cric.match.teams_2_r[0]['id']).html("("+ove(message.data.cric.match.teams_2_inn2_r[0]['balls'])+" overs)"); }
if(message.data.cric.match.teams_1_r[0]['extras']!=null){ jQuery('#extras_1_r_'+message.data.cric.match.teams_1_r[0]['id']).html("("+ove(message.data.cric.match.teams_1_r[0]['extras'])); } if(message.data.cric.match.teams_2_r[0]['extras']!=null){ jQuery('#extras_2_r_'+message.data.cric.match.teams_1_r[0]['id']).html("("+ove(message.data.cric.match.teams_2_r[0]['extras'])); } if(message.data.cric.match.teams_1_inn2_r[0]['extras']!=null){ jQuery('#extras_1_r_2_'+message.data.cric.match.teams_1_inn2_r[0]['id']).html("("+ove(message.data.cric.match.teams_1_inn2_r[0]['extras'])); } if(message.data.cric.match.teams_2_inn2_r[0]['extras']!=null){ jQuery('#extras_1_r_2_'+message.data.cric.match.teams_2_inn2_r[0]['id']).html("("+ove(message.data.cric.match.teams_2_inn2_r[0]['extras'])); }
//extras_1_r_2_ // if(prev_bat_team != message.data.cric.team_id){ jQuery('#widget_wrapper').load(document.URL + ' #widget_wrapper'); // } // prev_bat_team = message.data.cric.team_id // }
}); });
Full Scorecard
Team Dambulla
270/6
(40 overs)
Result
Team Colombo
262/6
(39 overs)
Colombo won by 4 runs (D/L Method)
Team Dambulla’s Innings
Batting | R | B | ||||
---|---|---|---|---|---|---|
Kusal Janith | b Dilruwan Perera | 59 | 40 | |||
Sangeeth Cooray | lbw by Dilruwan Perera | 15 | 24 | |||
TN Sampath | c Lasith Abeyrathne b Thisara Perera | 18 | 26 | |||
A. Priyanjan | lbw by Thisara Perera | 50 | 51 | |||
Sachithra Serasinghe | c Dilruwan Perera b Vishwa Fernando | 40 | 53 | |||
M. Siriwardana | not out | 51 | 29 | |||
L. Madushanka | c Lahiru Thirimanne b Vishwa Fernando | 22 | 15 | |||
Nishan Madushka | not out | 5 | 2 |
Bowling | O | M | R | W | E |
---|---|---|---|---|---|
V. Fernando | 7 | 0 | 64 | 2 | 9.14 |
Vikum Sanjaya | 2 | 0 | 24 | 0 | 12.00 |
Shehan Jayasuriya | 8 | 0 | 32 | 0 | 4.00 |
Dilruwan Perera | 7 | 0 | 39 | 2 | 5.57 |
L. Embuldeniya | 6 | 0 | 43 | 0 | 7.17 |
NLTC Perera | 7 | 0 | 44 | 2 | 6.29 |
D.De.Silva | 3 | 0 | 21 | 0 | 7.00 |
Team Colombo’s Innings
Batting | R | B | ||||
---|---|---|---|---|---|---|
Dilruwan Perera | (runout) Sangeeth Cooray | 8 | 11 | |||
Shehan Jayasuriya | c Ashan Priyanjan b Lahiru Gamage | 11 | 5 | |||
Lahiru Thirimanne | not out | 107 | 99 | |||
D.De.Silva | c Nishan Madushka b Amila Aponso | 41 | 39 | |||
Angelo Perera | lbw by Asitha Fernando | 26 | 25 | |||
Chamara Silva | c Kusal Janith b Asitha Fernando | 25 | 30 | |||
NLTC Perera | c Sachithra Serasinghe b Lahiru Gamage | 32 | 15 | |||
L. Abeyrathne | not out | 6 | 10 |
Bowling | O | M | R | W | E |
---|---|---|---|---|---|
L. Gamage | 7 | 0 | 47 | 2 | 6.71 |
A.Fernando | 8 | 0 | 47 | 2 | 5.88 |
L. Madushanka | 6 | 0 | 34 | 0 | 5.67 |
Sachithra Serasinghe | 8 | 0 | 68 | 0 | 8.50 |
MA Aponso | 8 | 0 | 49 | 1 | 6.13 |
TN Sampath | 1 | 0 | 8 | 0 | 8.00 |
A. Priyanjan | 1 | 0 | 7 | 0 | 7.00 |