Remap Sub-Directory


#1

Hey, I’m trying to remap a subdirectory to a folder inside the main directory. Like this:

http://subsir.domainname.com/

to -->

http://domnainname.com/subdir/

I want to do this to keep everything organized inside my domainname.com directory. I’m just not sure how to accomplish this.

Thanks,
Mike


#2

[quote]Hey, I’m trying to remap a subdirectory to a folder inside the main directory. Like this:

http://subsir.domainname.com/

to -->

http://domnainname.com/subdir/[/quote]
You’ve mixed up the terms a bit…

First of all, the part after the http:// is called the hostname. A Hostname can be a domain or a subdomain, it is not called a subdirectory.

Second, “folders” and “directories” are the same thing but directory is the more accurate term since a directory is simply a list and “folder” is just a metaphor for GUI-ness.

Also, the part of the URL that comes after the hostname is called the URL-path.

If you want the URL to stay the same (which is what you mean if you say “remap”) then you need to set the document root of the subdomain to the filesystem path of the subdirectory.

  1. Get the document root path of domainname.com from the Web Panel - it is called the “Web Directory”
  2. Append the url-path to this path
    Example: ‘/home/user/domain/’ becomes ‘/home/user/domain/subdir/’
  3. Set the document root of the subdomain to this path

If you want the URL to change, then edit the subdomain to be “Redirected” instead of “Fully hosted” and specify the new URL instead of a filesystem path.

:cool: openvein.org -//- One-time [color=#6600CC]$50.00 discount[/color] on [color=#0000CC]DreamHost[/color] plans: Use ATROPOS7


#3

Thanks for clearing that up.

-Mike