2

I'm trying to use LocationMatch to match an URL in a website's second-level subdomain but not in it's third-level subdomain. This is because I want to password protect some URLs at that level.

eg. level2.domain.com/some/url should match but not level3.level2.domain.com/some/url

Than I would apply the necessary directives to password protect the URLs.

Does LocationMatch match this part or the URL ? I don't think so, and if that's the case, what could I use to achieve the desired effect ?

Andrei
  • 1,606
  • 4
  • 19
  • 31

1 Answers1

1

I think you have to break up the locations into separate VirtualHost blocks and use ServerName / ServerAlias appropriately to specify the domains you want to cover...

e.dan
  • 7,275
  • 1
  • 26
  • 29