Table name = playerslist11
Table name2 = teams ( newsid is where the team id is found)
[php]// Connect to server and select databse
mysql_connect("$host", “$username”, “$password”)or die(“cannot connect”);
mysql_select_db("$db_name")or die(“cannot select DB”);
$sql="SELECT * FROM $playerslist11,teams Where WHERE playerslist11.team = teams.teamnameseason AND teams. teamname = (SELECT teamname from teams WHERE newsid = " . $teamid . ") ";
$result=mysql_query($sql);
// Define $color=1
$color=“1”;
echo ‘
".$rows['Team']." | ".$rows['Name']." | ".$rows['Salary']." |
".$rows['Team']." | ".$rows['Name']." | ".$rows['Salary']." |
mysql_close();
?>[/php]
My select code is the issue. Im trying to pull the stats above from playerslist11 by the team code found in the “teams” table. Just cant seem to grab it. I have nothing showing with the code i have…
Help anyone?