I have my site on a shared host but I am wanting to have a localhost where i can add in new things and change stuff etc...
All of my stuff works on my localhost except my menu where it does not seem to get the info from the database
here is part of the code where its not gathering the info. the stuff in red below is where the error starts.
here are the 2 errros i see
Notice: Undefined variable: row in C:\xampp\htdocs\menu.php on line 124
Notice: Trying to get property of non-object in C:\xampp\htdocs\menu.php on line 124
<ul class="teraMenu">
<li><a title="UFHL homepage" href="/">HOME</a></li>
<li><a title="UFHL Forums" href="/forum/forum.php" rel="nofollow">FORUMS</a></li>
<?
$result = mysql_query("select * from league") or die(mysql_error());
while($row = mysql_fetch_object($result))
{
?>
<li class="<? if($row->id==$_GET['league']) echo 'visible'; ?>">
<a class="" href="/standings/[COLOR="#FF0000"]<?=$row->id;?>"><?=$row->name;?>[/COLOR]</a>
<ul class="submenu0 <? if($row->id==$_GET['league']) echo 'visible'; ?>">
<li><a title="Standings" href="/standings/<?=$row->id;?>">STANDINGS</a></li>
<li><a title="Schedule" href="/schedule/<?=$row->id;?>">SCHEDULE</a></li>
<li>
<a href="#" class="moreDown">STATISTICS</a>
<ul class="submenu1">
<li><a title="Player" href="/statistics/player/<?=$row->id;?>?nav=4">PLAYER</a></li>
<li><a title="Goalie" href="/statistics/goalie/<?=$row->id;?>">GOALIE</a></li>
<li><a title="Goalie" href="/statistics/milestones/<?=$row->id;?>">MILESTONES</a></li>
<li><a title="League records" href="/statistics/records/<?=$row->id;?>">LEAGUE RECORDS</a></li>
</ul>
</li>
<li>
<a href="#" class="moreDown">TEAMS</a>
<ul class="submenu1">
<?
$result2=mysql_query("select * from divisions WHERE seasonid='$sid' and leagueid='".$row->id."' ORDER BY leagueid") or die(mysql_error());
while($row2=mysql_fetch_object($result2))
{
$result3=mysql_query("SELECT * FROM teams WHERE division='".$row2->id."' AND league='".$row->id."' AND name != 'admin' AND name != 'divadmin' ORDER BY name") or die(mysql_error());
while($row3 = mysql_fetch_object($result3))
{
echo '<li><a href="/team/?id='.$row3->id.'&league='.$row->id.'">'.$row3->name.'</a></li>';
}
}
?>
</ul>
</li>
<li><a title="Injuries" href="/injuries/<?=$row->id;?>">INJURIES</a></li>
</ul>
</li>
<?
}
?>