Fixes to profile lookup code
Changes to .htaccess files for hosting