aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--index.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/index.php b/index.php
index b57d6d4..6cbc25e 100644
--- a/index.php
+++ b/index.php
@@ -106,7 +106,11 @@ $schedule = $BostonFoodTrucks->schedule(array(
<?php foreach ($schedule['food_trucks'] as $truck): ?>
<tr>
<td class="company">
- <a href="<?= $truck['company_url'] ?>"><?= $truck['company'] ?></a>
+ <?php if ($truck['company_url']): ?>
+ <a href="<?= $truck['company_url'] ?>"><?= $truck['company'] ?></a>
+ <?php else: ?>
+ <?= $truck['company'] ?>
+ <?php endif; ?>
</td>
<td class="location">