Jump to content

Need if statement assistance


kemper

Recommended Posts

<?php

$confid = intval($_GET['conf']);

mysql_connect($sportsdb_host,$sportsdb_user,$sportsdb_pass);
@mysql_select_db($sportsdb_db) or die( "Unable to select database");

// Allow sorting to occur
$standings_sort = intval($_GET['sort']);
switch ($standings_sort) {
case 1: $sort_order = "teamname ASC"; break;
case 2: $sort_order = "teamwins DESC, teamties DESC, teamlosses ASC"; break;
case 3: $sort_order = "teamlosses DESC, teamwins ASC, teamties ASC"; break;
case 4: $sort_order = "teamties DESC, teamwins DESC, teamlosses ASC"; break;
case 5: $sort_order = "teamforfeits DESC, teamwins ASC, teamties ASC"; break;
case 6: $sort_order = "gamesplayed DESC, teamwins DESC, teamties DESC, teamlosses ASC"; break;
case 7: $sort_order = "teamrf DESC, teamwins ASC, teamties DESC, teamlosses ASC"; break;
case 8: $sort_order = "teamra DESC, teamwins DESC, teamties ASC, teamlosses DESC"; break;
case 9: $sort_order = "gamesbehind ASC, teamties DESC, teamwins DESC, teamlosses ASC"; break;
case 10: $sort_order = "points DESC, teamwins DESC, winningpct DESC"; break;
default: $standings_sort = 10; $sort_order = "points DESC, teamra ASC, teamrf DESC, teamname ASC";
}
$division_sort = "";

if ($confid > 0) {

// print the conference name
$resultconf = mysql_query("SELECT confname FROM sportsdb_conferences WHERE confid = $confid LIMIT 1");
$numconf = mysql_num_rows($resultconf);
if ($numconf == 0) die ("No such division");

opentable ("Spring 2008 Season Details");
print "<p><a href=\"index.php\">Back to division list</a></p>\n<hr />\n";

// Get the divisions

$resultconf = mysql_query("SELECT divname, divid FROM sportsdb_divs WHERE conference = $confid ORDER BY divorder");
$numconf = mysql_num_rows($resultconf);
if ($numconf == 0) die ("No data in this division");

while ($divs = mysql_fetch_array($resultconf, MYSQL_ASSOC)) {

// Loop through each division

$divname = $divs['divname'];

print "<h3><font color='#1c19a0'>$divname</font></h3>\n";

?>
<table width='100%' class='tbl-border'>
<tr><td class='tbl2' width='55%'><?php if ($standings_sort != 1) print "<a href=\"index.php?conf=$confid&sort=1\">"; ?><b>Team Name</b><?php if ($standings_sort != 1) print "</a>"; ?></td>
<td class='tbl2' align='center' width='5%'><?php if ($standings_sort != 6) print "<a href=\"index.php?conf=$confid&sort=6\">"; ?><strong>GP</strong><?php if ($standings_sort != 2) print "</a>"; ?></td>
<td class='tbl2' align='center' width='5%'><?php if ($standings_sort != 2) print "<a href=\"index.php?conf=$confid&sort=2\">"; ?><b>W</b><?php if ($standings_sort != 2) print "</a>"; ?></td>
<td class='tbl2' align='center' width='5%'><?php if ($standings_sort != 3) print "<a href=\"index.php?conf=$confid&sort=3\">"; ?><b>L</b><?php if ($standings_sort != 3) print "</a>"; ?></td>
<?php if ($show_ties) { ?>
<td class='tbl2' align='center' width='5%'><?php if ($standings_sort != 4) print "<a href=\"index.php?conf=$confid&sort=4\">"; ?><b>T</b><?php if ($standings_sort != 4) print "</a>"; ?></td>
<?php } ?>
<?php if ($forfeit) { ?>
<td class='tbl2' align='center' width='5%'><?php if ($standings_sort != 5) print "<a href=\"index.php?conf=$confid&sort=5\">"; ?><b>Forfeits</b><?php if ($standings_sort != 5) print "</a>"; ?></td>
<?php } ?>
<?php if ($show_rfra) { ?>
<td class='tbl2' align='center' width='5%'><?php if ($standings_sort != 7) print "<a href=\"index.php?conf=$confid&sort=7\">"; ?><b>GF</b><?php if ($standings_sort != 7) print "</a>"; ?></td>
<td class='tbl2' align='center' width='5%'><?php if ($standings_sort !=  print "<a href=\"index.php?conf=$confid&sort=8\">"; ?><b>GA</b><?php if ($standings_sort !=  print "</a>"; ?></td>
<?php } ?>
<?php if ($show_gb) { ?>
<td class='tbl2' align='center' width='5%'><?php if ($standings_sort != 9) print "<a href=\"index.php?conf=$confid&sort=9\">"; ?><b>GB</b><?php if ($standings_sort != 9) print "</a>"; ?></td>
<?php } ?>
<td class='tbl2' align='center' width='10%'><?php if ($standings_sort != 0) print "<a href=\"index.php?conf=$confid&sort=0\">"; ?><b>PCT</b><?php if ($standings_sort != 0) print "</a>"; ?></td>
<?php if ($show_points) { ?>
<td class='tbl2' align='center' width='5%'><?php if ($standings_sort != 10) print "<a href=\"index.php?conf=$confid&sort=10\">"; ?><b>Pts</b><?php if ($standings_sort != 10) print "</a>"; ?></td>
<?php } ?>
</tr>
<?php
$query = "SELECT COUNT(*) FROM sportsdb_teams WHERE teamdiv = {$divs['divid']}";
$result = mysql_query($query);
$result_exist = mysql_result($result,0);
if ($result_exist) {
	$query = "SELECT teamid, teamname, teamwins, teamties, teamlosses, teamforfeits, teamrf, teamra, (teamwins + teamties + teamlosses + teamforfeits) AS gamesplayed, (teamwins / (teamwins + teamlosses + teamforfeits)) AS winningpct, (teamwins - teamlosses - teamforfeits) AS leadervalue, (teamwins * $points_win + teamforfeits * $points_forfeit + teamties * $points_tie) AS points FROM sportsdb_teams WHERE teamdiv = {$divs['divid']} ORDER BY leadervalue DESC, teamties DESC LIMIT 1";
	$result = mysql_query($query) or die ("Error in query: $query");
	$results = mysql_fetch_array($result, MYSQL_ASSOC);
	$winningpct=number_format($results['winningpct'], 3);
	}

// Show the leader at the top for default sorting (games behind)

if ($standings_sort == 9) {

	print "<tr><td class='tbl1' width='55%'><em>{$results['teamname']}</em></td><td class='tbl1' align='center' width='5%'>{$results['gamesplayed']}</td><td class='tbl1' align='center' width='5%'>{$results['teamwins']}</td><td class='tbl1' align='center' width='5%'>{$results['teamlosses']}</td>";
	if ($show_ties) print "<td class='tbl1' align='center' width='5%'>{$results['teamties']}</td>";
	if ($forfeit) print "<td class='tbl1' align='center' width='5%'>{$results['teamforfeits']}</td>";
	if ($show_rfra) print "<td align='center' class='tbl1' width='5%'>{$results['teamrf']}</td><td align='center' class='tbl1' width='5%'>{$results['teamra']}</td>";
	if ($show_gb) print "<td class='tbl1' align='center' width='5%'>---</td>";
	print "<td class='tbl1' align='center' width='10%'>$winningpct</td>";
	if ($show_points) print "<td class='tbl1' align='center' width='5%'>{$results['points']}</td>";
	print "</tr>\n";
	}

if ($result_exist) {
$query="SELECT teamid, teamname, teamwins, teamties, teamlosses, teamforfeits, teamrf, teamra, (teamwins + teamties + teamlosses + teamforfeits) AS gamesplayed, (teamwins / (teamwins + teamlosses + teamforfeits)) AS winningpct, ((({$results['leadervalue']}) - (teamwins - teamlosses - teamforfeits)) / 2) AS gamesbehind, (teamwins * $points_win + teamforfeits * $points_forfeit + teamties * $points_tie) AS points FROM sportsdb_teams
WHERE teamdiv = {$divs['divid']}";

if ($standings_sort == 9) {
	$query .= " AND teamid != {$results['teamid']}";
	}
$query .= " AND active = 1" . $division_sort . " ORDER BY $sort_order";
$result=mysql_query($query);
$num=mysql_numrows($result);

while ($results = mysql_fetch_array($result, MYSQL_ASSOC)) {

	$winningpct=number_format($results['winningpct'], 3);
	$gamesbehind = number_format($results['gamesbehind'],1);

	if ($gamesbehind == "0.0") $gamesbehind = "---";

		print "<tr><td class='tbl1'><em>{$results['teamname']}</em></td><td class='tbl1' align='center'>{$results['gamesplayed']}</td><td class='tbl1' align='center'>{$results['teamwins']}</td><td class='tbl1' align='center'>{$results['teamlosses']}</td>";
		if ($show_ties) print "<td class='tbl1' align='center'>{$results['teamties']}</td>";
		if ($forfeit) print "<td class='tbl1' align='center'>{$results['teamforfeits']}</td>";
		if ($show_rfra) print "<td class='tbl1' align='center'>{$results['teamrf']}</td><td class='tbl1' align='center'>{$results['teamra']}</td>";
		if ($show_gb) print "<td class='tbl1' align='center'>$gamesbehind</td>";
		print "<td class='tbl1' align='center'>$winningpct</td>";
		if ($show_points) print "<td class='tbl1' align='center'>{$results['points']}</td>";
		print "</tr>\n";
		}
}
print "</table>
<table width='100%' class='tbl-border'><tr><td bgcolor='#FFFF00'>Results and Standings are not kept for Ages U-7 through U-10. The focus is on learning the game, playing safe, and HAVING FUN!</td></tr></table>\n";
}
?>

<form name="teamsort" method="post" action="<?php print $_SERVER['REQUEST_URI']; ?>">
<p>Show only <select name="teamtosort">
<option value="all">All teams</option>
<?php
$queryteams = "SELECT sportsdb_teams.teamname, sportsdb_teams.teamid FROM sportsdb_teams, sportsdb_divs WHERE sportsdb_teams.teamdiv = sportsdb_divs.divid AND sportsdb_divs.conference = $confid ORDER BY teamname";
$resultteams=mysql_query($queryteams);
$numteams=mysql_numrows($resultteams);

while ($teams = mysql_fetch_array($resultteams, MYSQL_ASSOC)) { 
print "<option value=\"{$teams['teamid']}\"";
if ($teams['teamid'] == $_POST['teamtosort']) print ' selected';
print ">{$teams['teamname']}</option>\n";
}
?>
</select>
<input type="submit" value="Go" />
</p>
</form>

<h3><font color='#1c19a0'>Upcoming Games</font></h3>
<?php
print "<table width='100%' class='tbl-border'>\n";
print "<tr><th class='tbl2'>Status</th><th class='tbl2'>Date</th><th class='tbl2'>Time</th><th class='tbl2'>Home Team</th><th class='tbl2'>Visiting Team</th>";
if ($show_fields) print "<th class='tbl2'>Field</th>";
$queryscores = "SELECT sportsdb_wins.winid, sportsdb_wins.status, sportsdb_wins.windate, sportsdb_wins.wintime, sportsdb_wins.game_date, sportsdb_wins.game_time, sportsdb_wins.rf, sportsdb_wins.ra, sportsdb_wins.wincomments, sportsdb_wins.field, sportsdb_wins.field_no, sportsdb_teams2.teamname AS winningteam, sportsdb_teams.teamname AS losingteam
FROM sportsdb_wins, sportsdb_teams AS sportsdb_teams2, sportsdb_teams, sportsdb_divs
WHERE sportsdb_teams.teamdiv = sportsdb_divs.divid AND sportsdb_divs.conference = $confid AND sportsdb_teams2.teamid = sportsdb_wins.winner AND sportsdb_teams.teamid = sportsdb_wins.loser AND sportsdb_wins.winortie = 3";

// Sort by team if specified
if (isset($_POST['teamtosort']) && $_POST['teamtosort'] != 'all') {
$teamtosort = intval($_POST['teamtosort']);
$queryscores .= " AND (sportsdb_wins.winner = $teamtosort OR sportsdb_wins.loser = $teamtosort)"; 
}

$queryscores .= " ORDER BY game_date ASC, game_time ASC";
$resultscores = mysql_query($queryscores);
$numscores = mysql_numrows($resultscores);

while ($scores = mysql_fetch_array($resultscores, MYSQL_ASSOC)) {

    $game_time = ($scores['game_time']!=null)?date("g:i a", strtotime($scores['game_time'])):'TBA';
    $game_date = ($scores['game_date']!=null)?date("l, F j",strtotime($scores['game_date'])):'* TBA *';

//$windateheader=$scores['windate'];
//$windateformatted=date("F d, Y",$windateheader);
//$wintime=$scores['wintime'];
//$hour=date('g',$wintime);
//$minute=date('i',$wintime);
//$ampm=date('a',$wintime);

print "<tr><td class='tbl1'>{$scores['status']}</td><td class='tbl1'>$game_date</td><td class='tbl1'>$game_time</td><td class='tbl1'>{$scores['winningteam']}</td><td class='tbl1'>{$scores['losingteam']}</td>";
if ($show_fields) print "<td class='tbl1'>{$scores['field']} {$scores['field_no']}</td>";
}
echo "</table>\n";

?>

<h3><font color='#1c19a0'>Past Scores</font></h3>
<?php
print "<table width='100%' class='tbl-border'>\n";
print "<tr><th class='tbl2'>Date</th><th class='tbl2'>Home Team</th><th class='tbl2'>Score</th><th class='tbl2'>Visiting Team</th><th class='tbl2'>Score</th>";
if ($show_fields) print "<th class='tbl2'>Field</th>\n";
$queryscores="SELECT sportsdb_wins.winid, sportsdb_wins.windate, sportsdb_wins.wintime, sportsdb_wins.game_date, sportsdb_wins.game_time, sportsdb_wins.rf, sportsdb_wins.ra, sportsdb_wins.wincomments, sportsdb_wins.field, sportsdb_wins.winortie, sportsdb_teams2.teamname AS winningteam, sportsdb_teams.teamname AS losingteam
FROM sportsdb_wins, sportsdb_teams AS sportsdb_teams2, sportsdb_teams, sportsdb_divs
WHERE sportsdb_teams.teamdiv = sportsdb_divs.divid AND sportsdb_divs.conference = $confid AND sportsdb_teams2.teamid = sportsdb_wins.winner AND sportsdb_teams.teamid = sportsdb_wins.loser AND sportsdb_wins.winortie != 3";

// Sort by team if specified
if (isset($_POST['teamtosort']) && $_POST['teamtosort'] != 'all') {
$teamtosort = intval($_POST['teamtosort']);
$queryscores .= " AND (sportsdb_wins.winner = $teamtosort OR sportsdb_wins.loser = $teamtosort)"; 
}

$queryscores .= " ORDER BY wintime ASC";
$resultscores=mysql_query($queryscores);
$numscores=mysql_numrows($resultscores);

while ($scores = mysql_fetch_array($resultscores, MYSQL_ASSOC)) {

    $game_time = ($scores['game_time']!=null)?date("g:i a", strtotime($scores['game_time'])):'TBA';
    $game_date = ($scores['game_date']!=null)?date("l, F j",strtotime($scores['game_date'])):'* TBA *';

//$windateheader=$scores['windate'];
//$windateformatted=date("F d, Y",$windateheader);
//$wintime=$scores['wintime'];
//$hour=date('g',$wintime);
//$minute=date('i',$wintime);
//$ampm=date('a',$wintime);

print "<tr><td class='tbl1'>$game_date</td><td class='tbl1'>{$scores['winningteam']}</td>";
print "<td class='tbl1' align='center'><b>{$scores['rf']}</b></td>
<td class='tbl1'>{$scores['losingteam']}</td>";
print "<td class='tbl1' align='center'><b>{$scores['ra']}</b></td>";
if ($show_fields) print "<td class='tbl1'>{$scores['field']}</td>";
if ($scores['winortie'] == 2 || $scores['winortie'] == 5) print " (ff)";
print "</td></tr>\n";
}
echo "</table>\n";
closetable ();
}

// List the conference

else {
opentable ("Spring 2008 Season");
print "<p>Click on the division name to view its schedules, results (U-11 & older), and standings (U-11 & older).</p>
<table align='center' border='1' id='table2' cellspacing='0' cellpadding='3'>
	<tr>
		<td bgcolor='#FFFF00'><font face='Arial' size='4'><b>NOTE:</b></font><p>
		<font face='Arial' size='2'>Results and Standings are not kept for Ages 
U-7 through U-10. The focus is on learning the game, playing safe, and HAVING 
FUN!</font></td>
	</tr>
</table><br>\n";

$query = "SELECT * FROM sportsdb_conferences ORDER BY conforder";
$result = mysql_query($query) or die("Error in query $query");
$num = mysql_num_rows($result);
while ($confs = mysql_fetch_array($result, MYSQL_ASSOC)) {
print "
<a href=\"index.php?conf={$confs['confid']}\">{$confs['confname']}</a><br>\n";
}
closetable ();
}


require_once "../side_right.php";
require_once "../footer.php";
?>

 

For our standing, we do not keep records and standings for certain young ages (confid < 12).  How can I include an if statement to not display the standings table for confid < 12?  Currently the table to displayed for all, with a highlighted statement stating that the certain standings are not kept.

 

Assistance is greatly appreciated.

Link to comment
https://forums.phpfreaks.com/topic/98981-need-if-statement-assistance/
Share on other sites

I am not getting error, per say.  With your replaced query, the confids > 12 show.  confid 1 through 11 do not show anything.  No schedules, no data.  Alll I get for those is "No such division"

 

For confid < 12, i do not want to show:

	<table width='100%' class='tbl-border'>
<tr><td class='tbl2' width='55%'><?php if ($standings_sort != 1) print "<a href=\"index.php?conf=$confid&sort=1\">"; ?><b>Team Name</b><?php if ($standings_sort != 1) print "</a>"; ?></td>
<td class='tbl2' align='center' width='5%'><?php if ($standings_sort != 6) print "<a href=\"index.php?conf=$confid&sort=6\">"; ?><strong>GP</strong><?php if ($standings_sort != 2) print "</a>"; ?></td>
<td class='tbl2' align='center' width='5%'><?php if ($standings_sort != 2) print "<a href=\"index.php?conf=$confid&sort=2\">"; ?><b>W</b><?php if ($standings_sort != 2) print "</a>"; ?></td>
<td class='tbl2' align='center' width='5%'><?php if ($standings_sort != 3) print "<a href=\"index.php?conf=$confid&sort=3\">"; ?><b>L</b><?php if ($standings_sort != 3) print "</a>"; ?></td>
<?php if ($show_ties) { ?>
<td class='tbl2' align='center' width='5%'><?php if ($standings_sort != 4) print "<a href=\"index.php?conf=$confid&sort=4\">"; ?><b>T</b><?php if ($standings_sort != 4) print "</a>"; ?></td>
<?php } ?>
<?php if ($forfeit) { ?>
<td class='tbl2' align='center' width='5%'><?php if ($standings_sort != 5) print "<a href=\"index.php?conf=$confid&sort=5\">"; ?><b>Forfeits</b><?php if ($standings_sort != 5) print "</a>"; ?></td>
<?php } ?>
<?php if ($show_rfra) { ?>
<td class='tbl2' align='center' width='5%'><?php if ($standings_sort != 7) print "<a href=\"index.php?conf=$confid&sort=7\">"; ?><b>GF</b><?php if ($standings_sort != 7) print "</a>"; ?></td>
<td class='tbl2' align='center' width='5%'><?php if ($standings_sort !=  print "<a href=\"index.php?conf=$confid&sort=8\">"; ?><b>GA</b><?php if ($standings_sort !=  print "</a>"; ?></td>
<?php } ?>
<?php if ($show_gb) { ?>
<td class='tbl2' align='center' width='5%'><?php if ($standings_sort != 9) print "<a href=\"index.php?conf=$confid&sort=9\">"; ?><b>GB</b><?php if ($standings_sort != 9) print "</a>"; ?></td>
<?php } ?>
<td class='tbl2' align='center' width='10%'><?php if ($standings_sort != 0) print "<a href=\"index.php?conf=$confid&sort=0\">"; ?><b>PCT</b><?php if ($standings_sort != 0) print "</a>"; ?></td>
<?php if ($show_points) { ?>
<td class='tbl2' align='center' width='5%'><?php if ($standings_sort != 10) print "<a href=\"index.php?conf=$confid&sort=10\">"; ?><b>Pts</b><?php if ($standings_sort != 10) print "</a>"; ?></td>
<?php } ?>
</tr>
<?php
$query = "SELECT COUNT(*) FROM sportsdb_teams WHERE teamdiv = {$divs['divid']}";
$result = mysql_query($query);
$result_exist = mysql_result($result,0);
if ($result_exist) {
	$query = "SELECT teamid, teamname, teamwins, teamties, teamlosses, teamforfeits, teamrf, teamra, (teamwins + teamties + teamlosses + teamforfeits) AS gamesplayed, (teamwins / (teamwins + teamlosses + teamforfeits)) AS winningpct, (teamwins - teamlosses - teamforfeits) AS leadervalue, (teamwins * $points_win + teamforfeits * $points_forfeit + teamties * $points_tie) AS points FROM sportsdb_teams WHERE teamdiv = {$divs['divid']} ORDER BY leadervalue DESC, teamties DESC LIMIT 1";
	$result = mysql_query($query) or die ("Error in query: $query");
	$results = mysql_fetch_array($result, MYSQL_ASSOC);
	$winningpct=number_format($results['winningpct'], 3);
	}

// Show the leader at the top for default sorting (games behind)

if ($standings_sort == 9) {

	print "<tr><td class='tbl1' width='55%'><em>{$results['teamname']}</em></td><td class='tbl1' align='center' width='5%'>{$results['gamesplayed']}</td><td class='tbl1' align='center' width='5%'>{$results['teamwins']}</td><td class='tbl1' align='center' width='5%'>{$results['teamlosses']}</td>";
	if ($show_ties) print "<td class='tbl1' align='center' width='5%'>{$results['teamties']}</td>";
	if ($forfeit) print "<td class='tbl1' align='center' width='5%'>{$results['teamforfeits']}</td>";
	if ($show_rfra) print "<td align='center' class='tbl1' width='5%'>{$results['teamrf']}</td><td align='center' class='tbl1' width='5%'>{$results['teamra']}</td>";
	if ($show_gb) print "<td class='tbl1' align='center' width='5%'>---</td>";
	print "<td class='tbl1' align='center' width='10%'>$winningpct</td>";
	if ($show_points) print "<td class='tbl1' align='center' width='5%'>{$results['points']}</td>";
	print "</tr>\n";
	}

if ($result_exist) {
$query="SELECT teamid, teamname, teamwins, teamties, teamlosses, teamforfeits, teamrf, teamra, (teamwins + teamties + teamlosses + teamforfeits) AS gamesplayed, (teamwins / (teamwins + teamlosses + teamforfeits)) AS winningpct, ((({$results['leadervalue']}) - (teamwins - teamlosses - teamforfeits)) / 2) AS gamesbehind, (teamwins * $points_win + teamforfeits * $points_forfeit + teamties * $points_tie) AS points FROM sportsdb_teams
WHERE teamdiv = {$divs['divid']}";

if ($standings_sort == 9) {
	$query .= " AND teamid != {$results['teamid']}";
	}
$query .= " AND active = 1" . $division_sort . " ORDER BY $sort_order";
$result=mysql_query($query);
$num=mysql_numrows($result);

while ($results = mysql_fetch_array($result, MYSQL_ASSOC)) {

	$winningpct=number_format($results['winningpct'], 3);
	$gamesbehind = number_format($results['gamesbehind'],1);

	if ($gamesbehind == "0.0") $gamesbehind = "---";

		print "<tr><td class='tbl1'><em>{$results['teamname']}</em></td><td class='tbl1' align='center'>{$results['gamesplayed']}</td><td class='tbl1' align='center'>{$results['teamwins']}</td><td class='tbl1' align='center'>{$results['teamlosses']}</td>";
		if ($show_ties) print "<td class='tbl1' align='center'>{$results['teamties']}</td>";
		if ($forfeit) print "<td class='tbl1' align='center'>{$results['teamforfeits']}</td>";
		if ($show_rfra) print "<td class='tbl1' align='center'>{$results['teamrf']}</td><td class='tbl1' align='center'>{$results['teamra']}</td>";
		if ($show_gb) print "<td class='tbl1' align='center'>$gamesbehind</td>";
		print "<td class='tbl1' align='center'>$winningpct</td>";
		if ($show_points) print "<td class='tbl1' align='center'>{$results['points']}</td>";
		print "</tr>\n";
		}
}
print "</table>

that is starting at line 56

  • 2 weeks later...

Getting back to this topic, uniflare's code:

$resultconf = mysql_query("SELECT confname FROM sportsdb_conferences WHERE confid = $confid AND confid < 12 LIMIT 1");

took everything off the page.  My original script displays Standings table, followed by schedules and results.  I want the schedules/results table to remain for confids <12.  The code should only affect the displaying of the Standings table as we do not keep standings for those ages (confid).

 

Maybe my issue is where I updated the query.  I thought it should be updated in the query above the standings table details.  I thought that was the query to update.  I must be wrong.

 

Assistance is greatly appreciated.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.