Within a function send a user message best way

Within a function send a user message best way

Hi,

Inside a function i want to send the user a visual message

No Alert in functions so cant use that
Info is only seen if you are admin

So .. what are my choices to inform the user of something occurring within a function ?

Any ideas

Thanks