Hi --
I am just trying to get an echo on my page, but all it's echoeing is the name, # members and member names. the headings for all the other categories are up, but the info is on top of the table completely disorganized. did i do something wrong? i just copied and pasted all the rest of the rows...
<?php
include 'misc.inc';
include 'head.asp';
/ connect to server(mysql) with pconnect for persistent
connection, not to close then reconnect /
mysql_pconnect("$host","$user","$password")
or die ("Couldn't connect to the server.");
/ connect to db (seattlebands) /
mysql_select_db("seattlebands")
or die ("Couldn't connect to the database.");
/query /
$query = "SELECT * from bands WHERE members = 5";
$result = mysql_query($query)
or die (mysql_error());
$num_results = mysql_num_rows($result);
echo '<span class="body">
Number of items found: '.$num_results.'</span>
<table width"100%" class="table">
<tr><td><b>Name</b></td>
<td><b># Members</b></td>
<td><b>Names</b></td>
<td><b>Genre</b></td>
<td><b>Where Played?</b></td>
<td><b>Who with Locally?</b></td>
<td><b>Who With Nat\'l?</b></td>
<td><b>On A Label?</b></td>
<td><b>Label Name</b></td>
<td><b>Have Manager?</b></td>
<td><b>Manager Name</b></td>
<td><b>When Formed</b></td>
<td><b>Want Promotion?</b></td>
<td><b>Fav Venues to play</b></td>
<td><b>Fav Promoter</b></td>
<td><b>Link to site</b></td>
<td><b>Where Formed?</b></td>
<td><b>Fav Promo Co</b></td>
<td><b>$ For Promotion</b></td>
<td><b>Fav Bands to play w/</b></td>
<td><b>Your draw</b></td>
</tr>';
//display results
for ($i=0; $i <$num_results; $i++)
{
$row = mysql_fetch_array($result);
echo '<tr class="table" valign="top">
<td>'.($i+1).'. ';
echo stripslashes($row['name']);
echo '</td><td>';
echo stripslashes($row['members']);
echo'</td><td>';
echo stripslashes($row['memberName']);
echo'</td></tr>';
// THIS IS WHERE IT STOPS ECHOEING INFO....
echo stripslashes($row['genre']);
echo'</td></tr>';
echo stripslashes($row['wherePlayed']);
echo'</td></tr>';
echo stripslashes($row['withWhoLoc']);
echo'</td></tr>';
echo stripslashes($row['withWhoNat']);
echo'</td></tr>';
echo stripslashes($row['label']);
echo'</td></tr>';
echo stripslashes($row['labelName']);
echo'</td></tr>';
echo stripslashes($row['manager']);
echo'</td></tr>';
echo stripslashes($row['managerName']);
echo'</td></tr>';
echo stripslashes($row['whenFormed']);
echo'</td></tr>';
echo stripslashes($row['wouldPay']);
echo'</td></tr>';
echo stripslashes($row['favVenue']);
echo'</td></tr>';
echo stripslashes($row['favBooker']);
echo'</td></tr>';
echo stripslashes($row['siteLink']);
echo'</td></tr>';
echo stripslashes($row['origin']);
echo'</td></tr>';
echo stripslashes($row['sold']);
echo'</td></tr>';
echo stripslashes($row['disco']);
echo'</td></tr>';
echo stripslashes($row['favPromoCo']);
echo'</td></tr>';
echo stripslashes($row['howMuch']);
echo'</td></tr>';
echo stripslashes($row['favPlay']);
echo'</td></tr>';
echo stripslashes($row['draw']);
echo'</td></tr>';
}
//close the results table
echo '</table>';
?>