update logic to allow civicrm to be installed in /profiles

https://issues.civicrm.org/jira/browse/CRM-15405
I think it would be safer to say `if ($pos === FALSE)`