Using the fputs() Function
<?php function custom_echo($string) { $output = "Custom Message: $string"; fputs(STDOUT, $string); } custom_echo("This is my custom echo function!"); ?>