I'm working on a PHP/SQL project that is a library of Dr.Seuss books. I'm wondering how to display just the book title (instead of a broken image link) when the book does not have an image.
Here is the code I have right now for displaying just the Cover image of the book.
<section class="books">
<?php foreach ($books as $book) : ?>
<a class="book grow" href="book.php?id=<?php echo $book['book_id']; ?>"> <img class="book-image" src="book-covers/<?php echo $book['book_image'];?>"></a>
<?php endforeach; ?>
</section>