There's a way to achieve what you ask with mod_rewrite directives in .htaccess, but before trying this, why not point to a separate directory?


With Best Regards,
Marat Khalili

On 19/09/16 21:41, thomas Armstrong wrote:

I have an Apache server, which main rootwebdir is '/usr/www/users/foo/' and ' <>' points there. However, I have some subdomains pointing within their directories:

| <> ---> /usr/www/users/foo/subdomain1 <> ---> /usr/www/users/foo/subdomain2 |

This causes me a problem: if anyone types ' <>', they find ' <>' with another URL, and I'd like to avoid it.

I wondered if there was any way to avoid this (e.g., showing a 404 page), by using a directive within the '.htaccess' file of '/usr/www/users/foo/subdomain1'.

Any other solution is welcome. Thank you very much.

Reply via email to