#---- sets database host name
$db_hostname = "localhost";
#--- sets database username
$db_username = "atsdb";
#---- sets database password
$db_password = "db_nhl009";
#---- sets database name
$db_name = "atsrdbnhl";
#----- connects to mysql database with the specified hostname, username & password
mysql_connect($db_hostname, $db_username, $db_password);
#---- selects the database
mysql_select_db($db_name);
#--- this variable is set to coloe the connection in downformat.inc.php
$dbconnect = "true";
$select='NHL';
$select="NHL";
$val="NHL";
$tz = getenv('TZ'); // Get current server time zone setting
putenv("TZ=EST5EDT"); // Change to US Eastern time zone or whatever you want
$lt = (localtime(time(),"TRUE"));
$ltt=$lt['tm_hour'];
putenv("TZ=$tz"); // Change it back to the original server time zone
//$tz = array ( 'PST' => -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);
$pacific_time=gmstrftime('%T', $pacific_time);
$startdate=$pacific_date;
$enddate=$pacific_date;
$tagval=$val;
#---- create expiry date
$select =$val;
#---- create expiry date
$value =$val;
#---collect the league information
$leagueqry=mysql_query("select league_no,league_id,league_name from ats_league1 where league_name='$value' ");
list($lno,$lid,$lname)=mysql_fetch_array($leagueqry);
?>
| Line moves :- |
One of the oldest forms of sports handicapping a game is watching the money moves at the Sportsbooks and the "Line Moves" software at ATS Database keeps track of where the money is moving. Either you need to watch the NFL line moves on game day or the changes from a busy day in college sports either football or basketball, the ATS Database line moves feature will track where the money is being laid down. In fact, you can monitor baseball line moves and hockey lines moves as well. One of the worst feelings in the world is getting hooked because you didn't have the right line and the ATS Database line moves software is a valuable betting tool that is free of charge and will improve your sports betting experience. Plus, when you click on the game matchup you want to monitor, the line moves software will tell you exactly the history of that betting line and when the money was on the move! |
SpMoneyLine = Spread Moneyline
/*---------------Code to display Current Streaks---------------*/
if($value=='NFL' || $value=='NBA' || $value=='NHL' || $value=='NCAAF' || $value=='NCAAB')
{
$curr_month=date('m');
if($curr_month>='08')
$cur_year=date('Y');
else
$cur_year=date('Y')-1;
$next_year=$cur_year+1;
}
else
{
$cur_year=date('Y');
}
if($value=='NFL')
{ $start_month='09' ;$end_month='02';
$end_date=$next_year.'-'.$end_month;
}
elseif($value=='NBA')
{
$start_month='10' ;$end_month='06';
$end_date=$next_year.'-'.$end_month;
}
elseif($value=='NHL')
{
$start_month='10' ;$end_month='06';
$end_date=$next_year.'-'.$end_month;
}
elseif($value=='CFL')
{
$start_month='06' ;$end_month='11';
$end_date=$cur_year.'-'.$end_month;
}
elseif($value=='NCAAF')
{
$start_month='08' ;$end_month='02';
$end_date=$next_year.'-'.$end_month;
}
elseif($value=='NCAAB')
{
$start_month='10' ;$end_month='04';
$end_date=$next_year.'-'.$end_month;
}
$start_date=$cur_year.'-'.$start_month;
$dateclause="( left(date,7) between '$start_date' and '$end_date' )";
function formatdate($sqldate)
{
list($yyyy, $mm, $dd) = explode('-',$sqldate);
$date = date('m-d-Y', mktime(0,0,0,$mm,$dd,$yyyy));
return $date;
}
$lqry=mysql_query("select league_no from ats_league1 where league_name='$value' ");
list($lno)=mysql_fetch_array($lqry);
$leagueqry=mysql_query("select league_no,league_id,league_name from ats_league1 where league_name='$value' ");
list($lno,$lid,$lname)=mysql_fetch_array($leagueqry);
#--collect the schedule from thegreek_schedule which is taken from
$dateqry=mysql_query("select distinct game_date from thegreek_schedule where game_date between '$startdate' and '$enddate' and league_no=$lno and (team1 not like '%Teams%' and team2 not like '%Teams%') and (team1 not like '%Live%' and team2 not like '%Live%') and (game_status!='3' or game_status!='2') and game_no1<'1001' and game_no2<'1002' order by game_date,game_no1 ");
$dnum=mysql_num_rows($dateqry);
if($dnum)
{
$date_array=array();
while($drow=mysql_fetch_array($dateqry))
{
$date_array[ ]=$drow['game_date'];
}
?>
| LEAGUE : |
#--for loop to display the matches date by date
for($dd=0;$dd
| DATE : |
if($select=='MLB' || $select=='NHL')
{
?>
| Game Time |
Teams |
Line Moves |
MoneyLine |
Spread |
SpMoneyLine |
Game Total |
O/U money |
}
else
{
?>
Game Time |
Teams |
Line Moves |
Spread |
SpMoneyLine |
MoneyLine |
Game Total |
O/U money |
}?>
#--get the table name from leaguename
$lname1=strtolower($lname);
$table=$lname1.'_teams';
#--collect the schedule inforamtion (gamedate,gametime,team1,team2,cris openers,etc) from thegreek_schedule
//echo "select * from thegreek_schedule where game_date ='$date' and league_no=$lno and (team1 not like '%Teams%' and team2 not like '%Teams%') and (team1 not like '%Live%' and team2 not like '%Live%') and (game_status!='3' and game_status!='2') and game_no1<'1001' and game_no2<'1002' and opening_line='yes' order by game_date,game_no1 ";
$gameqry=mysql_query("select * from thegreek_schedule where game_date ='$date' and league_no=$lno and (team1 not like '%Teams%' and team2 not like '%Teams%') and (team1 not like '%Live%' and team2 not like '%Live%') and (game_status!='3' and game_status!='2') and game_no1<'1001' and game_no2<'1002' and opening_line='yes' order by game_date,game_no1 ");
$rnum=mysql_num_rows($gameqry);
if($rnum)
{ $i=0;
while ($row=mysql_fetch_array($gameqry))
{
$home_cris="";
$road_cris="";
$date11=$row['game_date'];
$date = formatdate($date11);
$home_gameno=$row['game_no2'];
$road_gameno=$row['game_no1'];
//echo "select * from thegreek_schedule where game_date ='$date11' and league_no='$lno' and game_no1='$road_gameno' and game_no2='$home_gameno' and (game_status='0' or game_status='1') ";
$selcount=mysql_query("select * from thegreek_schedule where game_date ='$date11' and league_no='$lno' and game_no1='$road_gameno' and game_no2='$home_gameno' and (game_status='0' or game_status='1') ");
$count=mysql_num_rows($selcount);
$home_team=$row['team2'];
$road_team=$row['team1'];
/*new added */
$game_total=$row['game_total']; #--game total
$game_time=$row['game_time']; #--game total
$road_spread=$row['team1_spread']; #---road team spread
$home_spread=$row['team2_spread'];#---home team spread
$road_ML=$row['team1_ML'];#---road team moneyline
$home_ML=$row['team2_ML'];#---home team moneyline
$tot_overmoney=$row['tot_overmoney'];#---total point over money
$tot_undermoney=$row['tot_undermoney'];#---total point under money
$team1sp_money=$row['team1_spmoney'];
$team2sp_money=$row['team2_spmoney'];
$i++;
if($i%2==0 && $i%4!=0)
{
$bgcolor="#E8E8E8";
}
elseif($i%3==0)
{
$bgcolor="#FFCCCC";
}
elseif($i%4==0)
{
$bgcolor="#FFCC99";
}
elseif($i%5==0)
{
$bgcolor="#CCCC99";
}
else
{
$bgcolor="#FFFFCC";
}
?>
if($select=='MLB' || $select=='NHL')
{
?>
|
()
() |
|
|
|
|
|
|
}
else
{
?>
|
()
() |
|
|
|
|
|
|
}?>
if($rnum==$nullnum)
{?>
| No Matches Found For Current Date |
}
}#end while($roadrow)
}#ifrnum
else
{
?>
| No Matches Found For Current Date |
}
}#end for date array
?>
}#end if dnum
else
{
?>
| LEAGUE : |
| No Matches Found For Current Date |
}
?>
/*if($pst=="true")
{
}
elseif($pstpicks=="true")
{
}
else
{
require "Templates/atsdb2_footer_new.php";
}
*/
?>
|