added support for locations different than /