PHP newbie. I'm using this code
to print this:Code:<li class="amenities"><u>Amenities</u> (may vary by season): <?php foreach((get_the_category_excludeCat()) as $cat) { if (!($cat->cat_name=='')) echo $cat->cat_name . ', '; } ?></li>
Amenities (may vary by season): fireplace, jacuzzi/hot tub, kitchen/kitchenette, pets allowed, smoke free, waterfront,
How do I stop the final comma from printing?
thanks



Reply With Quote

Bookmarks