APP_PREFIX only worked if running from within a directory

We also need to account for the app being a suburl. We can do that by assuming that all app pages live under the same root that a landing page lives.