How to create a subdomain pointing to a file/subdirectory

1 post / 0 new
#1 Sun, 03/31/2019 - 16:17
R_O

How to create a subdomain pointing to a file/subdirectory

Hi,

I need to create subdomains to point files and subdirectories:

  1. subdomain.example.com pointing to example.com/subdomain < /public_html/subdomain/ >.

  2. file,example.com pointin to example.com/file.php < /public_html/file.php >.

I would prefer to automate the process with an script instead of making it one by one but I would appreciate your help to make it in any of the two ways.

Thank you