Source Code for /public/04-includes-and-functions/cap-img-demo.php
<?php
require_once('cap-img.php');
?>
<p>
Things in my fruitbowl:
</p>
<div class="gallery">
<?php
cap_img( '/img/fruit/apple.jpg', 'A red apple',
'From the tree in my back yard.' );
cap_img( '/img/fruit/bananas.jpg', 'Two ripe bananas',
"They're my favorite fruit." );
cap_img( '/img/fruit/plums.webp', 'A bowl of purple plums',
'I enjoy making jam every Autumn.' );
cap_img( '/img/fruit/kiwi.jpg', 'A halved kiwi fruit',
'I wish these grew in my part of the world.' );
?>
</div>