Subdomain Redirects
Schools may request the need to redirect a subdomain of their primary domain to a certain page on their primary domain for a variety of reasons. This is supported for Modern Campus Hosting with the following steps involving you and the Modern Campus Hosting team.
Step 1Link to this section
You create an SSL cert that has the subdomain(s) included. We do not recommend making the certificate wildcard due to the risk that imposes to your institution. An example certificate would cover the following domains: www.college.edu
, college.edu
(without the www), admissions.college.edu
, ce.college.edu
, and so on.
Step 2Link to this section
Send the certificate to Modern Campus along with a list of the subdomains you wish to redirect. Modern Campus will apply the certificate to your site and prepare your site to handle the subdomain redirects.
Step 3Link to this section
At the top of your .htaccess File, you will need to add directives to handle the subdomain(s). If there are multiple subdomains, you will need to add the directives for each subdomain.
# redirect for the admissions subdomain
RewriteCond %{HTTP_HOST} ^admissions\.college\.edu$ [NC]
RewriteRule ^ https://www.college.edu/admissions/ [R=301,L]
# redirect for the ce subdomain
RewriteCond %{HTTP_HOST} ^ce\.college\.edu$ [NC]
RewriteRule ^ https://www.college.edu/continuing-education/ [R=301,L]
Step 4Link to this section
Configure the DNS for the subdomain(s) to point to the same Modern Campus Hosting IP addresses used by your primary website. These IP addresses can be found in the Modern Campus Hosting section of the IP addresses documentation (login required).