-1

I have an issue where I'm trying to make it a "Trusted host patterns" on settings.php. It gets an issue of "The provided host name is not valid for this server."

I have tried many times to get it to work, the issue work with:

$settings['trusted_host_patterns'] = array(
  '^',
);

But will not get the following to work

$settings['trusted_host_patterns'] = array(
  '^sandbox\.dev$',
);

Thanks

enter image description here

0

According to your screenshot, your hostname is localhost, not sandbox.dev, so the correct regex would be ^localhost$

| improve this answer | |

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