hello again. i seem to be absolutely stumped on this one, it's even hard for me to 
explain, i'll do my best though.
ok, so what i need to do essentially is have the bands.php?band=thebandsname thing 
which the isset at the top of the code does.
then i need $band_spaces to equal $artist and $artist to equal $band_name
it may sound simple, but for the life of me, i can't figure out what in the hell to do.
i think my code can explain a little better so take a look.
thanks in advance, and thanks to all who've helped me over the past month or two.
if you have ANY question about this code or my problem, please e-mail me.

Matt Nigh

$link = mysql_connect("localhost","username","password");
if(!$link) die ("Could not connect to MySQL!");
if (!isset($band)) {
die("No artist specified.");
$sql = "select * from bands where (nospaces_bands = '$band')";
$result = mysql_query($sql);
if (mysql_num_rows($result) <= 0) {
die("Sorry, there was no artist found by that name.");
if (!$my_row = mysql_fetch_array($result)) {
die("Please specify an artist.");
$band = "nospaces_bands";
$band_spaces = "band_bands";
$id = "id";
$email = "email";
echo "<b>band name without spaces:</b> " . $my_row["$band"];
echo "<br><b>band name with spaces:</b> " . $my_row["$band_spaces"];
echo "<br><b>id:</b> " . $my_row["$id"];
echo "<br><b>email address:</b> " . $my_row[$email];

$band_spaces = $artist;

$sql_01 = "select * from shows where (artistname = '$artist')";
$result_01 = mysql_query($sql_01);
if (mysql_num_rows($result_01) <= 0) {
die("<br><br>No shows found.");
$my_row_01 = mysql_fetch_array($result_01);

$artist = "artistname";
$venue = "venue";
$time = "time";
echo "<br><br><hr><b>artist name with spaces:</b> " . $my_row_01["$artist"];
echo "<br><b>venue:</b> " . $my_row_01["$venue"];
echo "<br><b>time:</b> " . $my_row_01["$time"];

$artist = $band_name;

$sql_02 = "select * from releases where (bandname = '$band_name')";
$result_02 = mysql_query($sql_02);
if (mysql_num_rows($result_02) <= 0) {
die("No releases found.");
$my_row_02 = mysql_fetch_array($result);
$band_name = "bandname";
$albumtitle = "albumtitle";
$email = "email";
echo "<br><br><hr><b>artist name with spaces from releases:</b> " . 
echo "<br><b>album name:</b> " . $my_row_02["$albumtitle"];
echo "<br><b>album code:</b> " . $my_row_02["$albumcode"];


Reply via email to