Update buildTickets.php

Added full php tags and updated the top with an auto-bailout if buildTicketsQueueID not set.