I'm using Drupal 7, Context and Multisites. A Context determines which Block to render based on the domain's URL. This works fine for the live site with the actual URL.

My dev environment uses Domain aliases to make it work. For sampledomain.com, I have an alias for sampledomain.local. Context seems to ignore this alias and skips rendering the block on my dev machine.

Is this a known bug with Context/Multisites? Or is there an additional configuration option to make this work?

  • 1
    What happens if you hardcode your hosts file to use localhost for the remote ip lookup (e.g. sampledomain.com May 12, 2015 at 17:21
  • My hosts file currently redirects sampledomain.local to
    – Ryre
    May 12, 2015 at 17:27
  • Sure. I'm just asking what happens if you fake it. I know that on some Apache setups for example (Win vs Linux), some HTTP env vars are missing. If we can control for server environment, that's one less variable factor. May 12, 2015 at 17:38
  • Sorry, I don't understand what you're asking. I'm using a Vagrant box running an Ubuntu LAMP stack, and believe Apache to be running correctly. I can debug into the code and see the relevant $_SERVER values.
    – Ryre
    May 12, 2015 at 18:28
  • That's all I was asking. May 12, 2015 at 18:43

1 Answer 1


I was able to use Context Debug All to determine that the context is actually being loaded. The error is related to a different issue.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.