Environment:
I want to redirect a client by checking his subdomain. There are two issues regarding the redirection: a) from his URL, I need to select a specific application version and b) the client can not be sent to a different URL.
Scenario:
- Access the subdomain.example.com (URL)
- index.php triggers a query to the database and find out which version of the application should be redirected
- The client is redirected to the correct application (v1, v2, ..., vN) in the same HOST
- The URL must remain the same
- Each version of the application has its own index