I've got a match database at:
http://www.mancity.net/Test/fixtures.html
and I want the background colour of the row to change depending on whether the match is played at home or away.
Using the discussion relating to IF (Field)>0 etc...I've created this code:
if ($rec{'Venue'} = Away) {
print qq|<tr bgcolor="#E64C26">|;
}
if ($rec{'Venue'} = Home) {
print qq|<tr bgcolor="#C0C0C0">|;
}
else {
print qq|<tr bgcolor="#FFFFFF">|;
}
print qq|
BUT, it doesn't work. Is there something wrong with the "=" sign? Should I be using another character???
Ta.
Scall
http://www.mancity.net/Test/fixtures.html
and I want the background colour of the row to change depending on whether the match is played at home or away.
Using the discussion relating to IF (Field)>0 etc...I've created this code:
if ($rec{'Venue'} = Away) {
print qq|<tr bgcolor="#E64C26">|;
}
if ($rec{'Venue'} = Home) {
print qq|<tr bgcolor="#C0C0C0">|;
}
else {
print qq|<tr bgcolor="#FFFFFF">|;
}
print qq|
BUT, it doesn't work. Is there something wrong with the "=" sign? Should I be using another character???
Ta.
Scall