I wonder if it is possible to use the .htaccess file to route my domain directly to a subdirectory on my server?
I bought a web hosting package from a regular web host where my .com domain is connected to my root directory of my server. I wonder if it is possible to somehow upload the .htaccess file to the root directory of my server, which automatically routes domain.com (/index.php or /index.html) to domain.com/some-directory / ...
And, of course, I do not want the address bar to be updated to domain.com/some-directory. I want my regular domain to just extract files from a subdirectory instead of the root directory.
Just for a better overview on my server.
So, when calling mydomain.com, it displays index.html (or .php) from my root directory on my server. However, I want mydomain.com to display /subdirectory/index.html.
If possible, how can I do this? This is so bad? Is there something I was not thinking about? is there more boot time or something like that with this approach?
Thanks in advance. Matt
: this is possible with the DNS setting in my web admin panel. I can edit all DNS records.
source
share