I need the proper php syntax to handle a situation with my website's breadcrum links for product pages. All of my items are derived from a MySQL database.
The inventory items are organized either by itemCategory or itemAuthor. Not all items have an itemCategory associated with them so in the database they are NULL. All items however, have an itemAuthor.
What I basically want to say is:
If the item has a value for itemCategory, echo the itemCategory. If itemCategory is NULL, echo itemAuthor instead.
Thanks for any help.
echo !is_null($row['itemCategory']) ? $row['itemCategory'] : $row['itemAuthor'];?