factor out to isPHP() function