If you're comfortable with the security implications in your environment (as I was in mine...) then you can:
replace: <?=$ticket->getname()?>
with: <?=$ticket->getExtId()?>
Sorry to reply to this thread so late...
By the way, if anyone knows how to setup OSTicket such that you only provide the email address to see it's associated tickets, I'd be very interested in that. The environment I'm using OSTicket in doesn't need this security measure, and the convenience of only requiring an email address would be appreciated by my users.