Youtube Forecast

-8); //$pacific_time = time() + ($tz['PST'] * 3600); $tz = array ( 'EST' => -5); $pacific_time = time() + ($tz['EST'] * 3600); $lt = localtime($pacific_time, TRUE); if ($lt['tm_isdst']) $pacific_time += 3600; $pacific_date=gmstrftime('%Y-%m-%d', $pacific_time); list($y2, $m2, $d2) = split("-", $pacific_date); $month=gmstrftime('%A', $pacific_time); $curmonth=date('m'); if($league_name =='') { $league_name='NBA'; } $val=$league_name; $teamtable=strtolower($league_name).'_teams'; $datatable=strtolower($league_name).'_data1'; $sel_league=$league_name; require "league_season.inc.php"; switch($league_name) { case 'NFL':$league_no='1';break; case 'NCAAF':$league_no='2';break; case 'NBA':$league_no='3';break; case 'MLB':$league_no='5';break; case 'NHL':$league_no='7';break; case 'CFL':$league_no='18';break; } if($league_name=='MLB' || $league_name=='NBA' || $league_name=='NHL') { if($_REQUEST['srch_date']) { $srch_date = $_REQUEST['srch_date']; $startdate = $enddate=$srch_date; } else { $srch_date=$pacific_date; $startdate = $enddate=$srch_date; } } else { $cur_season='2018'; IF($week=='') { } else { $selectweek=mysqli_query($link,"select distinct date as date from $datatable where season='$cur_season' and week='$week' order by date "); while($srow=mysqli_fetch_array($selectweek)) { $gamedatearray[]=$srow['date']; } $datearrsize=sizeof($gamedatearray); $datearrval=$datearrsize-1; $startdate=$gamedatearray[0]; $enddate=$gamedatearray[$datearrval]; } } ?>



LEAGUE:-

"; if($league_name=='NCAAF') { $hteamqry=mysqli_query($link,"select team_id,team_name from $teamtable1 where (new_teamname='$team2' or team_name ='$team2' or score_teamname='$team2' or display_name='$team2' or nick_name='$team2')"); } else { $hteamqry=mysqli_query($link,"select team_id,team_name from $teamtable1 where (new_teamname='$team2' or team_name ='$team2' )"); } list($homeid,$hometeam)=mysqli_fetch_array($hteamqry); // echo "roadteam=$roadteam
"; $league1=strtolower($league_name); if($league_name=='CFL') { $baseimgpath='/wp-content/themes/mh_newsdesk_child/images/'.$league1.'/'.$league1.'_images/'; $img1=$baseimgpath.$roadteam.'.gif'; $img2=$baseimgpath.$hometeam.'.gif'; if($roadteam=='') $img1='dummy1.jpg'; if($hometeam=='') $img2='dummy1.jpg'; } elseif($league_name=='NFL') { $baseimgpath='/wp-content/themes/mh_newsdesk_child/images/'.$league1.'/'.$league1.'_images/'; $img1=$baseimgpath.strtolower($roadteam).'.gif'; $img2=$baseimgpath.strtolower($hometeam).'.gif'; if($roadteam=='') $img1='dummy1.jpg'; if($hometeam=='') $img2='dummy1.jpg'; } else { $roadteam1=strtolower($roadteam); $hometeam1=strtolower($hometeam); $baseimgpath='/wp-content/themes/mh_newsdesk_child/images/'.$league1.'/'.$league1.'_images/'; $img1=$baseimgpath.$roadteam1.'.gif'; $img2=$baseimgpath.$hometeam1.'.gif'; if($roadteam1=='') $img1='dummy1.jpg'; if($hometeam1=='') $img2='dummy1.jpg'; } $dateclause="date<'$todays_date' "; if($league_no=='1' || $league_no=='18' || $league_no=='3' || $league_no=='2')#--leagueno 1 for NFL,18 for CFL,3 for NBA { if($team1_spread<0 && $team2_spread>0) { $road_cris=$team1_spread; $home_cris=$game_total; } elseif($team2_spread<0 && $team1_spread>0) { $road_cris=$game_total; $home_cris=$team2_spread; } elseif($team2_spread==0 && $team1_spread==0) { $road_cris=$team1_spread; $home_cris=$game_total; } $home_cris=abs($home_cris); $road_cris=abs($road_cris); } elseif($league_no=='5' || $league_no=='7') #--5 is league no for MLB & 7 is for NHL { if($team2_ML<0 && $team1_ML>0) { $home_cris=$team2_ML; $road_cris=$game_total; } elseif($team2_ML>0 && $team1_ML<0) { $home_cris=$game_total; $road_cris=$team1_ML; } elseif(($team2_ML<0 && $team1_ML<0) && ($team2_ML!=$team1_ML)) { if($team2_ML<$team1_ML) { $home_cris=$team2_ML; $road_cris=$game_total; } elseif($team2_ML>$team1_ML) { $home_cris=$game_total; $road_cris=$team1_ML; } } elseif(($team2_ML<0 && $team1_ML<0) && ($team2_ML==$team1_ML)) { if($tot_undermoney<0 && $tot_overmoney>0) { $home_cris=$team2_ML; $road_cris=$game_total; } elseif($tot_undermoney>0 && $tot_overmoney<0) { $home_cris=$game_total; $road_cris=$team1_ML; } elseif(($tot_undermoney<0 && $tot_overmoney<0) && ($tot_undermoney!=$tot_overmoney)) { if($tot_undermoney<$tot_overmoney) { $home_cris=$team2_ML; $road_cris=$game_total; } elseif($tot_undermoney>$tot_overmoney) { $home_cris=$game_total; $road_cris=$team1_ML; } } elseif(($tot_undermoney<0 && $tot_overmoney<0) && ($tot_undermoney==$tot_overmoney)) { if($team2_spread<0 && $team1_spread>0) { $home_cris=$team2_ML; $road_cris=$game_total; } elseif($team2_spread>0 && $team1_spread<0) { $home_cris=$game_total; $road_cris=$team1_ML; } elseif(($team2_spread<0 && $team1_spread<0) && ($team2_spread!=$team1_spread)) { if($team2_spread<$team1_spread) { $home_cris=$team2_ML; $road_cris=$game_total; } elseif($team2_spread>$team1_spread) { $home_cris=$game_total; $road_cris=$team1_ML; } } elseif(($team2_spread<0 && $team1_spread<0) && ($team2_spread==$team1_spread)) { $home_cris='pk'; $road_cris='pk'; } }#2nd main elseif }#main elseif }#end of elseif for league if($road_cris==$game_total) { $road_cris='O/U :'.$road_cris; $home_cris='SIDE :'.$home_cris; } else { $road_cris='SIDE :'.$road_cris; $home_cris='O/U :'.$home_cris; } //echo "select auto_id,final_avg,final_num,road_withou_result,road_withoutou_result,home_withou_result,home_withoutou_result from ats_forecast where league_no='$leagueno' and game_date='$game_date' and road_gameno='$gameno1' and home_gameno='$gameno2'
"; $qry=mysqli_query($link,"select auto_id,final_avg,final_num,road_withou_result,road_withoutou_result,home_withou_result,home_withoutou_result from ats_forecast where league_no='$leagueno' and game_date='$game_date' and road_gameno='$gameno1' and home_gameno='$gameno2'"); list($auto_id,$final_avg,$final_num,$road_withou_result,$road_withoutou_result,$home_withou_result,$home_withoutou_result)=mysqli_fetch_array($qry); list($disp_road,$disp_home)=split('~',$final_avg); $roadval='road_'.$auto_id; $homeval='home_'.$auto_id; list($road_finalnum,$home_finalnum)=split('~',$final_num); $tot_finalnum=$road_finalnum+$home_finalnum; $totfinalval=$disp_road+$disp_home; $road_withou_resultarr=explode("~",$road_withou_result); $road_cow=$road_withou_resultarr[1]; $home_withou_resultarr=explode("~",$home_withou_result); $home_cow=$home_withou_resultarr[1]; if($league_name=='MLB' || $league_name=='NHL') { $mvi1=mysqli_query($link,"select market_value,value_index,grade from mvi_table where league_no='$leagueno' and team_id='$roadid' order by date desc limit 1"); list($market_value1,$value_index1,$grade1)=mysqli_fetch_row($mvi1); list($hmvs_avg, $homescore11_avg, $roadscore11_avg, $display1) = calculate_MVS($league_name, 'Home', $roadid); list($amvs_avg, $homescore22_avg, $roadscore22_avg, $display2) = calculate_MVS($league_name, 'Road', $roadid); $mvi_avg1 = round(calculate_middle($hmvs_avg, $amvs_avg), 0); if($mvi_avg1 == 0) $mvi_avg1 = 100; $market_value1 = $mvi_avg1; $mvi2=mysqli_query($link,"select market_value,value_index,grade from mvi_table where league_no='$leagueno' and team_id='$homeid' order by date desc limit 1"); list($market_value2,$value_index2,$grade2)=mysqli_fetch_row($mvi2); list($hmvs_avg, $homescore11_avg, $roadscore11_avg, $display1) = calculate_MVS($league_name, 'Home', $homeid); list($amvs_avg, $homescore22_avg, $roadscore22_avg, $display2) = calculate_MVS($league_name, 'Road', $homeid); $mvi_avg2 = round(calculate_middle($hmvs_avg, $amvs_avg), 0); if($mvi_avg2 == 0) $mvi_avg2 = 100; $market_value2 = $mvi_avg2; } else { ##MVS for CFL,NFL,NCAAF $mvi1=mysqli_query($link,"select value_index,grade from mvi_table where league_no='$leagueno' and team_id='$roadid' order by date desc limit 1"); list($value_index1,$grade1)=mysqli_fetch_row($mvi1); $mvi2=mysqli_query($link,"select value_index,grade from mvi_table where league_no='$leagueno' and team_id='$homeid' order by date desc limit 1"); list($value_index2,$grade2)=mysqli_fetch_row($mvi2); $mvs1=mysqli_query($link,"select home_off_avg,home_def_avg,road_off_avg,road_def_avg from ats_averages where league_name='$league_name' and team_id='$roadid'"); //echo "HPF=$home_off_avg---------HPA=$home_def_avg
APF=$road_off_avg---------APA=$road_def_avg
"; list($HPF1,$HPA1,$APF1,$APA1)=mysqli_fetch_row($mvs1); if($HPF1>'0' && $HPA1>'0') { $ats_val12=$HPA1-$HPF1; } //echo "ats_val12=$ats_val12
"; if($APF1>'0' && $APA1>'0') { $ats_val14=$APA1-$APF1; } //echo "ats_val14=$ats_val14
"; $market_value1=($ats_val12+$ats_val14)/2; $market_value1=round($market_value1,2); //echo "market_value1=$market_value1
"; $mvs2=mysqli_query($link,"select home_off_avg,home_def_avg,road_off_avg,road_def_avg from ats_averages where league_name='$league_name' and team_id='$homeid'"); list($HPF2,$HPA2,$APF2,$APA2)=mysqli_fetch_row($mvs2); if($HPF2>'0' && $HPA2>'0') { $ats_val22=$HPA2-$HPF2; } //echo "ats_val22=$ats_val22
"; if($APF2>'0' && $APA2>'0') { $ats_val24=$APA2-$APF2; } // echo "ats_val24=$ats_val24
"; $market_value2=($ats_val22+$ats_val24)/2; //echo "market_value2=$market_value2
"; $market_value2=round($market_value2,2); } //echo "roadid=$roadid-------------homeid=$homeid"; ##80%stats $road_super='';$home_super='';$roadstatnum='0';$road_msg='';$home_msg='';$road_su='';$home_su='';$clubstatper=''; $clubmsg='';$starcolor='';$statstype='';$starcolor1='';$statstype1=''; $clubsucount='';$clubstarcolor=''; ##Check for Team trends stats //echo "AAselect message,su_count,su_percentage from random_queries where league_no='$league_no' and game_date='$game_date' and team_a='$roadid' and su_percentage>='80' order by su_percentage desc limit 1
"; $road_stat=mysqli_query($link,"select message,su_count,su_percentage from random_queries where league_no='$league_no' and game_date='$game_date' and team_a='$roadid' and su_percentage>='80' order by su_percentage desc limit 1 "); if($road_stat)#1 { $roadstatnum=mysqli_num_rows($road_stat); //echo "roadstatnum=$roadstatnum
"; if($roadstatnum != '' && $roadstatnum != '0') { list($road_msg,$road_su,$road_super)=mysqli_fetch_row($road_stat); //echo "AA road_super=$road_super
"; $starcolor='blue'; $statstype='team'; } else #1 { //echo "sdds"; ##NO result in team trends ,so now check in smart stats //echo "BBselect message,su_count,su_percentage from ats_smartstats where league_no='$league_no' and game_date='$game_date' and team_a='$roadid' and su_percentage>='80' order by su_percentage desc limit 1
"; $road_stat=mysqli_query($link,"select message,su_count,su_percentage from ats_smartstats where league_no='$league_no' and game_date='$game_date' and team_a='$roadid' and su_percentage>='80' order by su_percentage desc limit 1 "); if($road_stat)#2 { $roadstatnum=mysqli_num_rows($road_stat); //echo "roadstatnum=$roadstatnum
"; if($roadstatnum != '' && $roadstatnum != '0') { list($road_msg,$road_su,$road_super)=mysqli_fetch_row($road_stat); //echo "BB road_super=$road_super
"; $starcolor='blue'; $statstype='smart'; } else #2 { ##NO result in smart trends ,so now check in ATS Matchup stats //echo "CCselect message,su_count,su_percentage from v5random_queries where league_no='$league_no' and game_date='$game_date' and team_a='$roadid' and su_percentage>='80' order by su_percentage desc limit 1
"; $road_stat=mysqli_query($link,"select message,su_count,su_percentage from v5random_queries where league_no='$league_no' and game_date='$game_date' and team_a='$roadid' and su_percentage>='80' order by su_percentage desc limit 1 "); if($road_stat)#3 { $roadstatnum=mysqli_num_rows($road_stat); //echo "roadstatnum=$roadstatnum
"; if($roadstatnum != '' && $roadstatnum != '0') { list($road_msg,$road_su,$road_super)=mysqli_fetch_row($road_stat); //echo "CC road_super=$road_super
"; $starcolor='blue'; $statstype='v5'; } else #3 { ##NO result in smart trends ,so now check in h2h stats //echo "DDselect message,su_count,su_percentage from h2hrandom_queries where league_no='$league_no' and game_date='$game_date' and team_a='$roadid' and su_percentage>='80' order by su_percentage desc limit 1
"; $road_stat=mysqli_query($link,"select message,su_count,su_percentage from h2hrandom_queries where league_no='$league_no' and game_date='$game_date' and team_a='$roadid' and su_percentage>='80' order by su_percentage desc limit 1 "); if($road_stat)#4 { $roadstatnum=mysqli_num_rows($road_stat); if($roadstatnum != '' && $roadstatnum != '0') { list($road_msg,$road_su,$road_super)=mysqli_fetch_row($road_stat); //echo "DD road_super=$road_super
"; $starcolor='blue'; $statstype='h2h'; } }#if($road_stat)#4 else { $road_super='';$starcolor='';$statstype=''; } }#end else3 }#end if($road_stat)#3 }#end else2 }#end if($road_stat)#2 }#end else1 }#end if($road_stat)#1 //echo "$road_super-----------$starcolor----------$statstype
"; if($starcolor=='' && $statstype=='') { //echo "EEselect message,su_count,su_percentage from random_queries where league_no='$league_no' and game_date='$game_date' and team_a='$roadid' and su_percentage>'0' and su_percentage<'35' order by su_percentage desc limit 1
"; $road_stat=mysqli_query($link,"select message,su_count,su_percentage from random_queries where league_no='$league_no' and game_date='$game_date' and team_a='$roadid' and su_percentage>'0' and su_percentage<'35' order by su_percentage desc limit 1 "); if($road_stat)#5 { $roadstatnum=mysqli_num_rows($road_stat); if($roadstatnum != '' && $roadstatnum != '0') { list($road_msg,$road_su,$road_super)=mysqli_fetch_row($road_stat); //echo "EE road_super=$road_super
"; $starcolor='red'; $statstype='team'; } else #5 { ##NO result in team trends ,so now check in smart stats //echo "FFselect message,su_count,su_percentage from ats_smartstats where league_no='$league_no' and game_date='$game_date' and team_a='$roadid' and su_percentage>'0' and su_percentage<'35' order by su_percentage desc limit 1
"; $road_stat=mysqli_query($link,"select message,su_count,su_percentage from ats_smartstats where league_no='$league_no' and game_date='$game_date' and team_a='$roadid' and su_percentage>'0' and su_percentage<'35' order by su_percentage desc limit 1 "); if($road_stat)#6 { $roadstatnum=mysqli_num_rows($road_stat); if($roadstatnum != '' && $roadstatnum != '0') { list($road_msg,$road_su,$road_super)=mysqli_fetch_row($road_stat); //echo "FF road_super=$road_super
"; $starcolor='red'; $statstype='smart'; } else #6 { ##NO result in smart trends ,so now check in ATS Matchup stats //echo "GGselect message,su_count,su_percentage from v5random_queries where league_no='$league_no' and game_date='$game_date' and team_a='$roadid' and su_percentage>'0' and su_percentage<'35' order by su_percentage desc limit 1
"; $road_stat=mysqli_query($link,"select message,su_count,su_percentage from v5random_queries where league_no='$league_no' and game_date='$game_date' and team_a='$roadid' and su_percentage>'0' and su_percentage<'35' order by su_percentage desc limit 1 "); if($road_stat)#7 { $roadstatnum=mysqli_num_rows($road_stat); if($roadstatnum != '' && $roadstatnum != '0') { list($road_msg,$road_su,$road_super)=mysqli_fetch_row($road_stat); //echo "GG road_super=$road_super
"; $starcolor='red'; $statstype='v5'; } else #7 { ##NO result in smart trends ,so now check in h2h stats //echo "HHselect message,su_count,su_percentage from h2hrandom_queries where league_no='$league_no' and game_date='$game_date' and team_a='$roadid' and su_percentage>'0' and su_percentage<'35' order by su_percentage desc limit 1
"; $road_stat=mysqli_query($link,"select message,su_count,su_percentage from h2hrandom_queries where league_no='$league_no' and game_date='$game_date' and team_a='$roadid' and su_percentage>='80' order by su_percentage desc limit 1 "); if($road_stat)#8 { $roadstatnum=mysqli_num_rows($road_stat); if($roadstatnum != '' && $roadstatnum != '0') { list($road_msg,$road_su,$road_super)=mysqli_fetch_row($road_stat); //echo "HH road_super=$road_super
"; $starcolor='red'; $statstype='h2h'; } else { $road_super=''; $starcolor=''; $statstype=''; } }#end if($road_stat)#8 }#end else#7 }#roadstatnum7 }#end else#6 }#roadstatnum6 }#end else#5 }#roadstatnum5 }#if($starcolor=='' && $statstype=='') //echo "AAA+$road_msg-------------$road_su--------$road_super--------statstype=$statstype-----starcolor=$starcolor

"; /* $home_stat=mysqli_query($link,"select message,su_count,su_percentage from random_queries where league_no='$league_no' and game_date='$game_date' and team_a='$homeid' and su_percentage>='80' order by su_percentage desc limit 1 "); if($home_stat) { $homestatnum=mysqli_num_rows($home_stat); if($homestatnum>0) { list($home_msg,$home_su,$home_super)=mysqli_fetch_row($home_stat); $starcolor='blue'; } else { $home_stat=mysqli_query($link,"select message,su_count,su_percentage from random_queries where league_no='$league_no' and game_date='$game_date' and team_a='$homeid' and su_percentage<='35' order by su_percentage desc limit 1 "); if($home_stat) { $homestatnum=mysqli_num_rows($home_stat); if($homestatnum>0) { list($home_msg,$home_su,$home_super)=mysqli_fetch_row($home_stat); $starcolor='red'; } } } } */ #############################HOME################################ ##Check for Team trends stats //echo "AAselect message,su_count,su_percentage from random_queries where league_no='$league_no' and game_date='$game_date' and team_a='$homeid' and su_percentage>='80' order by su_percentage desc limit 1
"; $home_stat=mysqli_query($link,"select message,su_count,su_percentage from random_queries where league_no='$league_no' and game_date='$game_date' and team_a='$homeid' and su_percentage>='80' order by su_percentage desc limit 1 "); if($home_stat)#1 { $homestatnum=mysqli_num_rows($home_stat); //echo "homestatnum=$homestatnum
"; if($homestatnum != '' && $homestatnum != '0') { list($home_msg,$home_su,$home_super)=mysqli_fetch_row($home_stat); //echo "AA road_super=$home_super
"; $starcolor1='blue'; $statstype1='team'; } else #1 { ##NO result in team trends ,so now check in smart stats //echo "BBselect message,su_count,su_percentage from ats_smartstats where league_no='$league_no' and game_date='$game_date' and team_a='$homeid' and su_percentage>='80' order by su_percentage desc limit 1
"; $home_stat=mysqli_query($link,"select message,su_count,su_percentage from ats_smartstats where league_no='$league_no' and game_date='$game_date' and team_a='$homeid' and su_percentage>='80' order by su_percentage desc limit 1 "); if($home_stat)#2 { $homestatnum=mysqli_num_rows($home_stat); //echo "homestatnum=$homestatnum
"; if($homestatnum != '' && $homestatnum != '0') { list($home_msg,$home_su,$home_super)=mysqli_fetch_row($home_stat); //echo "BB road_super=$home_super
"; $starcolor1='blue'; $statstype1='smart'; } else #2 { ##NO result in smart trends ,so now check in ATS Matchup stats //echo "CCselect message,su_count,su_percentage from v5random_queries where league_no='$league_no' and game_date='$game_date' and team_a='$homeid' and su_percentage>='80' order by su_percentage desc limit 1
"; $home_stat=mysqli_query($link,"select message,su_count,su_percentage from v5random_queries where league_no='$league_no' and game_date='$game_date' and team_a='$homeid' and su_percentage>='80' order by su_percentage desc limit 1 "); if($home_stat)#3 { $homestatnum=mysqli_num_rows($home_stat); //echo "homestatnum=$homestatnum
"; if($homestatnum != '' && $homestatnum != '0') { list($home_msg,$home_su,$home_super)=mysqli_fetch_row($home_stat); //echo "CC road_super=$home_super
"; $starcolor1='blue'; $statstype1='v5'; } else #3 { ##NO result in smart trends ,so now check in h2h stats //echo "DDselect message,su_count,su_percentage from h2hrandom_queries where league_no='$league_no' and game_date='$game_date' and team_a='$homeid' and su_percentage>='80' order by su_percentage desc limit 1
"; $home_stat=mysqli_query($link,"select message,su_count,su_percentage from h2hrandom_queries where league_no='$league_no' and game_date='$game_date' and team_a='$homeid' and su_percentage>='80' order by su_percentage desc limit 1 "); if($home_stat)#4 { $homestatnum=mysqli_num_rows($home_stat); //echo "homestatnum=$homestatnum
"; if($homestatnum != '' && $homestatnum != '0') { list($home_msg,$home_su,$home_super)=mysqli_fetch_row($home_stat); //echo "DD road_super=$home_super
"; $starcolor1='blue'; $statstype1='h2h'; } }#if($home_stat)#4 else { $home_super='';$starcolor1='';$statstype1=''; } }#end else3 }#end if($home_stat)#3 }#end else2 }#end if($home_stat)#2 }#end else1 }#end if($home_stat)#1 // echo "starcolor1=$starcolor1------------statstype1=$statstype1
"; if($starcolor1=='' && $statstype1=='') { //echo "EEselect message,su_count,su_percentage from random_queries where league_no='$league_no' and game_date='$game_date' and team_a='$homeid' and su_percentage>'0' and su_percentage<'35' order by su_percentage desc limit 1
"; $home_stat=mysqli_query($link,"select message,su_count,su_percentage from random_queries where league_no='$league_no' and game_date='$game_date' and team_a='$homeid' and su_percentage>'0' and su_percentage<'35' order by su_percentage desc limit 1 "); if($home_stat)#5 { $homestatnum=mysqli_num_rows($home_stat); //echo "homestatnum=$homestatnum
"; if($homestatnum != '' && $homestatnum != '0') { list($home_msg,$home_su,$home_super)=mysqli_fetch_row($home_stat); //echo "EE road_super=$home_super
"; $starcolor1='red'; $statstype1='team'; } else #5 { ##NO result in team trends ,so now check in smart stats //echo "FFselect message,su_count,su_percentage from ats_smartstats where league_no='$league_no' and game_date='$game_date' and team_a='$homeid' and su_percentage>'0' and su_percentage<'35' order by su_percentage desc limit 1
"; $home_stat=mysqli_query($link,"select message,su_count,su_percentage from ats_smartstats where league_no='$league_no' and game_date='$game_date' and team_a='$homeid' and su_percentage>'0' and su_percentage<'35' order by su_percentage desc limit 1 "); if($home_stat)#6 { $homestatnum=mysqli_num_rows($home_stat); //echo "homestatnum=$homestatnum
"; if($homestatnum != '' && $homestatnum != '0') { list($home_msg,$home_su,$home_super)=mysqli_fetch_row($home_stat); //echo "FF road_super=$home_super
"; $starcolor1='red'; $statstype1='smart'; } else #6 { ##NO result in smart trends ,so now check in ATS Matchup stats //echo "GGselect message,su_count,su_percentage from v5random_queries where league_no='$league_no' and game_date='$game_date' and team_a='$homeid' and su_percentage>'0' and su_percentage<'35' order by su_percentage desc limit 1
"; $home_stat=mysqli_query($link,"select message,su_count,su_percentage from v5random_queries where league_no='$league_no' and game_date='$game_date' and team_a='$homeid' and su_percentage>'0' and su_percentage<'35' order by su_percentage desc limit 1 "); if($home_stat)#7 { $homestatnum=mysqli_num_rows($home_stat); //echo "homestatnum=$homestatnum
"; if($homestatnum != '' && $homestatnum != '0') { list($home_msg,$home_su,$home_super)=mysqli_fetch_row($home_stat); //echo "GG road_super=$home_super
"; $starcolor1='red'; $statstype1='v5'; } else #7 { ##NO result in smart trends ,so now check in h2h stats //echo "HHselect message,su_count,su_percentage from h2hrandom_queries where league_no='$league_no' and game_date='$game_date' and team_a='$homeid' and su_percentage>'0' and su_percentage<'35' order by su_percentage desc limit 1
"; $home_stat=mysqli_query($link,"select message,su_count,su_percentage from h2hrandom_queries where league_no='$league_no' and game_date='$game_date' and team_a='$homeid' and su_percentage>'0' and su_percentage<'35' order by su_percentage desc limit 1 "); if($home_stat)#8 { $homestatnum=mysqli_num_rows($home_stat); //echo "homestatnum=$homestatnum
"; if($homestatnum != '' && $homestatnum != '0') { list($home_msg,$home_su,$home_super)=mysqli_fetch_row($home_stat); //echo "HH road_super=$home_super
"; $starcolor1='red'; $statstype1='h2h'; } else { $home_super=''; $starcolor1=''; $statstype1=''; } }#end if($home_stat)#8 }#end else#7 }#homestatnum7 }#end else#6 }#homestatnum6 }#end else#5 }#homestatnum5 }#if($starcolor=='' && $statstype=='') //echo "BBB+$home_msg-------------$home_su--------$home_super--------statstype=$statstype1-----starcolor=$starcolor1

"; if($road_super!='' && $home_super!='') { if(trim($road_super)>trim($home_super)) { $clubstatper=$road_super; $clubmsg=$road_msg; $clubsucount=$road_su; $clubstarcolor=$starcolor; } elseif(trim($road_super)

Vs.
Date:
Time:
Generated from
Previous Games

Forecast
(O/U )
% C.O.W %
DMVI MSV
() MVI ()
   80% CLUB STAT       80% CLUB STAT   
: SU