Protecting a Subdomain

Discussion in 'Setting-up protection' started by gci1875, Jul 19, 2008.

  1. gci1875

    gci1875 New Member

    Joined:
    Jul 14, 2008
    Messages:
    4
    Want to protect entire subdomain (eg name.site.com).

    Looks like I can protect subdomain via htpasswd.

    However, I'd like to protect by mod_rewrite (new_rewrite). Getting message in Protection setup that:

    (RewriteRule doesn't work in .htaccess files on this server)

    Hosting with Mosso. Tell me that I have Rewrite permissions on account. Put .htaccess file in subdomain and no change in protection settings.

    Can't figure it out.

    Help.

    The subdomain folder is outside the main domain folder on the server. AMember is installed on main domain.

    I'd like to keep aMember installed on main domain, if possible. Mainly only want members to see the subdomain.
  2. skippybosco

    skippybosco CGI-Central Partner Staff Member

    Joined:
    Aug 22, 2006
    Messages:
    2,526
    is your subdomain a subdirectory of your main domain?

    domain.com/sub = sub.domain.com

    if so then this is fairly straightforward.. is it possible to have your host structure it this way?
  3. gci1875

    gci1875 New Member

    Joined:
    Jul 14, 2008
    Messages:
    4
    No, it's not - hence the issue.

    I know I could install aMember on the subdomain, but I really want to reserve the subdomain to be seen only by members.

    Anyone know a way to do this? Alex?
  4. skippybosco

    skippybosco CGI-Central Partner Staff Member

    Joined:
    Aug 22, 2006
    Messages:
    2,526
    is there a reason you can not make the subdomain a directory of the main domain (ie. ask your host to configure it that way) and then protect that folder?
  5. gci1875

    gci1875 New Member

    Joined:
    Jul 14, 2008
    Messages:
    4
    No, can't do that. Asked and Mosso only pust subdomain folders in root at same level as any other domain.
  6. gci1875

    gci1875 New Member

    Joined:
    Jul 14, 2008
    Messages:
    4
    Heard from Anton by support ticket.

    He said it's not possible to protect a subdomain whose folder is in the root folder with the main domain.
  7. skippybosco

    skippybosco CGI-Central Partner Staff Member

    Joined:
    Aug 22, 2006
    Messages:
    2,526
    I would go back to Mosso and ask for an exception to their policy on subdomains under a directory of the root.. this is a fairly standard configuration so there should be no technical reason they can't do this, may just mean they have to manually set it up if their auto config software doesn't do it this way by default.

Share This Page