cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Subdomain redirect

Why is it that when i create a subdomain in this case youtube.gefnet.com  the redirection works no problem but I also setup gefnet.com/youtube as a redirection but whenever you go to that url it says forbidden it's trying to read the directory and there is nothing there because it's supposed to redirect to the youtube channel that i have already set

 

Advice? 

1 REPLY 1
Employee

Hi @gfultz1

 

Thank you for your post. Since the second example is on the primary domain, have you set a "youtube" directory in the hosting to manage the redirect it is referencing? 

 

The way it seems to be setup is gefnet.com is pointed to the hosting platform, so when someone types in gefnet.com/youtube  they are referencing the hosting/sub-directory. If this is the case, that directory will need to have a rule that tells the routing that once that is referenced, it will need to redirect outside of the server.  

 

You may complete that rule by creating an index.php file with the following PHP redirect example (replacing the url with that of the redirect destination):

<?php header('Location: http://domain.tld'); ?>  

 

Hope this helps!

-TechFly