Jump to content

Suppressing a blank field


cororon

Recommended Posts

HiI have some code that displays event listings.If any of the fields like $row['event_artist'] or $row['event_detail'] or $row['event_contact'] are blank or NUll I get a blank line (because of the <br />). Is there a way I can easily get around that without having to put in IF/ELSE statements to check if the fields is blank and then using different code?echo $row['event_name'] . "<br> " . $row['event_start_time'] . $row['event_venue'] . "<br />" . $row['event_artist'] . "<br />" . $row['event_detail'] . "<br />" . $row['event_contact'] . "<br><br>"; Many thanks

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...