Confusing Perl and PHP