I am not PHP programmer, but in Perl if you don't have return it will return the value of the variable that happens to be on the last line of the subroutine.