Prevent change of subdomain

Using a single web hosting account to host multiple sites

Prevent change of subdomain

Postby Moughnin » Thu Aug 21, 2008 11:13 am

Hi -

I have a number of applications that run as sub domains (vhosts on a different server). Some are https others http:

https://apps1.example.com
http://apps2.example.com
https://apps3.example.com
etc....

How can I prevent (redirect) the user from changing the sub domain?

I've tried things along the lines of:

RewriteCond %{HTTP_HOST} !^(app1|app2)\.example\.com$ [NC]
RewriteRule .* - [L]
RewriteRule ^/$ apex/f?p=412:1 [R=301]

But it still allows the the change to be made....

Thanks in advance for any input you can provide.
Betzy
Moughnin
 
Posts: 2
Joined: Thu Aug 21, 2008 9:06 am

Thank You!!

Postby Moughnin » Thu Aug 21, 2008 12:59 pm

Hi -

Please disregard.

I found the answer (and a few others) in the forum - I had a number of rewrites that were off the mark.

I also found a few different options as well.

This place is great :)

Thanks!
Betz
Moughnin
 
Posts: 2
Joined: Thu Aug 21, 2008 9:06 am


Return to Domain Handling

Who is online

Users browsing this forum: No registered users and 29 guests

cron