Improve support for hosting in a sub-directory
Remove some unwanted search code for performance