Subdomains

webrack

Verified User
Joined
Aug 6, 2003
Messages
10
Location
California
Ok i've had this problem for two months now and im getting a little pissed off I can't get it to work. So I am trying to make a sudomain right? So I go to ....

- Subdomain Management

then create a subdomain

Add Subdomain: test.christlab.com

So now I have to set it to go somewere. Now I go to site redirection. and put...

Local URL Path: /test
Destination URL: http://www.mysite.com

now I go to http://test.christlab.com and it doesn't work? What am I doing wrong here?

I get this.......
...............................................................................
Forbidden
You don't have permission to access / on this server.

Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.


--------------------------------------------------------------------------------

Apache/1.3.27 Server at test.christlab.com Port 80
..............................................................................

So that means the redirection doesn't work its just pointing to the server folder /test anyone have any idea?
 
Hello,

When you add a redirect, it needs to actually have the redirect path in the address when you want to be redirected, ie:

http://christlab.com/test
http://test.christlab.com/test

We don't currently have a subdomain redirect feature, but a simple workaround is to put an index.html file in the /test directory, with the following:
Code:
<html>
<script language="Javascript">
location.href="http://www.christlab.net"
</script>
</html>

John
 
but that would use my bandwith everytime they go to the site :( not cool. So no subdomains with DA then?

you.yourdomain.com?
 
Hello,

As stated above, we don't currently have that feature, but there have been a few requets to add it, so we will in time.

Another method (that which we would be implementing) would be to create an .htaccess file in the subdomain's directory with the following contents:
Code:
Redirect / [url]http://www.christlab.net/[/url]

This will redirect the subdomain to http://www.christlab.net/

John
 
A better way for manual redirection is to use the following saved as index.php:

PHP:
<?php header("Location: http://www.domainhere.com/directory1/directory2"); ?>

It doesn't rely on javascript :)

HTH,
Matt :)
 
DirectAdmin Support said:
Hello,

As stated above, we don't currently have that feature, but there have been a few requets to add it, so we will in time.

Another method (that which we would be implementing) would be to create an .htaccess file in the subdomain's directory with the following contents:
Code:
Redirect / [url]http://www.christlab.net/[/url]

This will redirect the subdomain to http://www.christlab.net/

John

I tried this and it doesn't work created.
 
Back
Top