| ";
# print "| Player | First | Last | Any | Two + | Three + | ";
# $playervalid = "n"; $player = "";
# $sql = "select PLP_ID, PLP_Surname, PLP_Forename from Football_PL_Players where ((PLP_Team = $TEAM_NUMBER and (PLP_SquadNo > 0 and PLP_SquadNo <= 99)) or (PLP_LoanedTo = $TEAM_NUMBER and (PLP_LoanedToSquad > 0 and PLP_LoanedToSquad <= 99))) and PLP_ID = " . mysql_real_escape_string($_REQUEST['scorer']);
# $res = mysql_query($sql);
# while ($row = mysql_fetch_array($res)) {
# $player = trim(stripslashes($row['PLP_Forename'] . " " . $row['PLP_Surname']));
# $sql_bet2 = "select * from BT_Betting888 where BT_Merchant = \"$selected_merchant\" and BT_Event = \"$longmatch\" and BT_SubEvent = \"First Goalscorer\" and BT_Selection = '$player' limit 1";
# $res_bet2 = mysql_query($sql_bet2);
# while ($row_bet2 = mysql_fetch_array($res_bet2)) {
# $player = $row_bet2['BT_Selection'];
# print "| $player | " . displayOdds($row_bet2['BT_Odds'], $row_bet2['BT_Fractional'], $selected_merchant, $row_bet2['BT_URL']) . " | ";
#
# $sql_bet = "select * from BT_Betting888 where BT_Merchant = \"$selected_merchant\" and BT_Event = \"$longmatch\" and BT_SubEvent = \"Last Goalscorer\" and BT_Selection = \"{$row_bet2['BT_Selection']}\" limit 1";
# $res_bet = mysql_query($sql_bet);
# while ($row_bet = mysql_fetch_array($res_bet)) print displayOdds($row_bet['BT_Odds'], $row_bet['BT_Fractional'], $selected_merchant, $row_bet['BT_URL']);
# print " | ";
#
# $sql_bet = "select * from BT_Betting888 where BT_Merchant = \"$selected_merchant\" and BT_Event = \"$longmatch\" and BT_SubEvent = \"Anytime Goalscorer\" and BT_Selection = \"{$row_bet2['BT_Selection']}\" limit 1";
# $res_bet = mysql_query($sql_bet);
# while ($row_bet = mysql_fetch_array($res_bet)) print displayOdds($row_bet['BT_Odds'], $row_bet['BT_Fractional'], $selected_merchant, $row_bet['BT_URL']);
# print " | ";
#
# $sql_bet = "select * from BT_Betting888 where BT_Merchant = \"$selected_merchant\" and BT_Event = \"$longmatch\" and BT_SubEvent = \"Player to Score 2 or More\" and BT_Selection = \"{$row_bet2['BT_Selection']}\" limit 1";
# $res_bet = mysql_query($sql_bet);
# while ($row_bet = mysql_fetch_array($res_bet)) print displayOdds($row_bet['BT_Odds'], $row_bet['BT_Fractional'], $selected_merchant, $row_bet['BT_URL']);
# print " | ";
#
# $sql_bet = "select * from BT_Betting888 where BT_Merchant = \"$selected_merchant\" and BT_Event = \"$longmatch\" and BT_SubEvent = \"Hat-trick Scorer\" and BT_Selection = \"{$row_bet2['BT_Selection']}\" limit 1";
# $res_bet = mysql_query($sql_bet);
# while ($row_bet = mysql_fetch_array($res_bet)) print displayOdds($row_bet['BT_Odds'], $row_bet['BT_Fractional'], $selected_merchant, $row_bet['BT_URL']);
# print " | ";
# print "| Other goalscorer odds: | ";
# }
# }
# $sql_bet2 = "select * from BT_Betting888 where BT_Merchant = \"$selected_merchant\" and BT_Event = \"$longmatch\" and BT_SubEvent = \"First Goalscorer\" and BT_Selection != 'No Goalscorer' and BT_Selection != '$player' order by BT_Odds limit 5";
# $res_bet2 = mysql_query($sql_bet2);
# while ($row_bet2 = mysql_fetch_array($res_bet2)) {
# $player = $row_bet2['BT_Selection'];
# print "| $player | " . displayOdds($row_bet2['BT_Odds'], $row_bet2['BT_Fractional'], $selected_merchant, $row_bet2['BT_URL']) . " | ";
#
# $sql_bet = "select * from BT_Betting888 where BT_Merchant = \"$selected_merchant\" and BT_Event = \"$longmatch\" and BT_SubEvent = \"Last Goalscorer\" and BT_Selection = \"{$row_bet2['BT_Selection']}\" limit 1";
# $res_bet = mysql_query($sql_bet);
# while ($row_bet = mysql_fetch_array($res_bet)) print displayOdds($row_bet['BT_Odds'], $row_bet['BT_Fractional'], $selected_merchant, $row_bet['BT_URL']);
# print " | ";
#
# $sql_bet = "select * from BT_Betting888 where BT_Merchant = \"$selected_merchant\" and BT_Event = \"$longmatch\" and BT_SubEvent = \"Anytime Goalscorer\" and BT_Selection = \"{$row_bet2['BT_Selection']}\" limit 1";
# $res_bet = mysql_query($sql_bet);
# while ($row_bet = mysql_fetch_array($res_bet)) print displayOdds($row_bet['BT_Odds'], $row_bet['BT_Fractional'], $selected_merchant, $row_bet['BT_URL']);
# print " | ";
#
# $sql_bet = "select * from BT_Betting888 where BT_Merchant = \"$selected_merchant\" and BT_Event = \"$longmatch\" and BT_SubEvent = \"Player to Score 2 or More\" and BT_Selection = \"{$row_bet2['BT_Selection']}\" limit 1";
# $res_bet = mysql_query($sql_bet);
# while ($row_bet = mysql_fetch_array($res_bet)) print displayOdds($row_bet['BT_Odds'], $row_bet['BT_Fractional'], $selected_merchant, $row_bet['BT_URL']);
# print " | ";
#
# $sql_bet = "select * from BT_Betting888 where BT_Merchant = \"$selected_merchant\" and BT_Event = \"$longmatch\" and BT_SubEvent = \"Hat-trick Scorer\" and BT_Selection = \"{$row_bet2['BT_Selection']}\" limit 1";
# $res_bet = mysql_query($sql_bet);
# while ($row_bet = mysql_fetch_array($res_bet)) print displayOdds($row_bet['BT_Odds'], $row_bet['BT_Fractional'], $selected_merchant, $row_bet['BT_URL']);
# print " | ";
# }
# $sql_bet2 = "select * from BT_Betting888 where BT_Merchant = \"$selected_merchant\" and BT_Event = \"$longmatch\" and BT_SubEvent = \"First Goalscorer\" and BT_Selection = 'No Goalscorer' order by BT_Odds";
# $res_bet2 = mysql_query($sql_bet2);
# while ($row_bet2 = mysql_fetch_array($res_bet2)) {
# $player = $row_bet2['BT_Selection'];
# print "| $player | " . displayOdds($row_bet2['BT_Odds'], $row_bet2['BT_Fractional'], $selected_merchant, $row_bet2['BT_URL']) . " | ";
#
# $sql_bet = "select * from BT_Betting888 where BT_Merchant = \"$selected_merchant\" and BT_Event = \"$longmatch\" and BT_SubEvent = \"Last Goalscorer\" and BT_Selection = \"{$row_bet2['BT_Selection']}\" limit 1";
# $res_bet = mysql_query($sql_bet);
# while ($row_bet = mysql_fetch_array($res_bet)) print displayOdds($row_bet['BT_Odds'], $row_bet['BT_Fractional'], $selected_merchant, $row_bet['BT_URL']);
# print " | | ";
# }
# print "
Many more markets available on our betting page | ";
print "";
} else {
print "Prediction NOT Logged
Sorry, there was a problem with your prediction and has NOT been logged. Please try again and if the problem persists, please contact us via the contact us at the bottom of the page. ";
}
} }
if ($PARAMETER1 == "prediction-history") { # prediction history
if ($loggedin != "y") { fError(); print " "; require("fb_bottom.php"); exit; }
print "Your Prediction History";
print " | Date | Opponents | V | H - A Actual | H - A Prediction | ";
$lastrow = 0;
$sql = "select PLE_HomeScore, PLE_DateTime, PLE_AwayScore, PLG_HomeTeam, PLG_AwayTeam, PLG_Date, PLE_Scorer, PLE_Flag, PLG_HomeScorer, PLG_AwayScorer, PLG_HomeScore, PLG_AwayScore from Football_PL_Predictions, Football_GA_Games where PLE_User = $US_ID and PLG_ID = PLE_Match order by PLG_Date desc, PLE_DateTime desc";
$res = mysql_query($sql);
while ($row = mysql_fetch_array($res)) {
$prediction = $row['PLE_HomeScore'] . " - " . $row['PLE_AwayScore'];
$date = $row['PLG_Date']; $day = substr($date, 6, 2); $month = substr($date, 4, 2); $year = substr($date, 0, 4);
if ($TEAM_NAME == $row['PLG_HomeTeam']) { $venue = "H"; } else { $venue = "A"; }
if ($row['PLG_HomeScore'] == -1) { $row['PLG_HomeScore'] = ""; $row['PLG_AwayScore'] = ""; }
$scorer = " " . plPlayer($row['PLE_Scorer']);
if ($row['PLE_Flag'] == "X") { $prediction = "" . $prediction . " " . $scorer . ""; } else { $prediction = $prediction . " " .$scorer; }
#if ($PLG_HomeScorer == -1) { $PLG_HomeScorer = 0; }
#if ($PLG_AwayScorer == -1) { $PLG_AwayScorer = 0; }
if ($venue == "H") {
print "| $day/$month/$year | {$row['PLG_AwayTeam']} | $venue | {$row['PLG_HomeScore']} - {$row['PLG_AwayScore']} " . plPlayer($row['PLG_HomeScorer']) . " | $prediction | ";
} else {
print "| $day/$month/$year | {$row['PLG_HomeTeam']} | $venue | {$row['PLG_HomeScore']} - {$row['PLG_AwayScore']} " . plPlayer($row['PLG_AwayScorer']) . " | $prediction | ";
}
}
print " "; }
if ($PARAMETER1 == "future-matches") { # future predictions
if ($loggedin != "y") { fError(); print " |