How to configure Trusted_Host_Settings for subdomains?
The documentation does not give an example of a subdomain.
For example, I have an Add-On domain that points to website.info, but the subdomain is mainsite.com/website.info
It's actually documented in
settings.php file as in examples:
<?php $settings['trusted_host_patterns'] = array( '^example\.com$', // Matches naked domain only. '^.+\.example\.com$', // Matches any subdomains. '^subdomain\.example\.com', // Matches a specific subdomain. );
You can easily define any naked or sub-domain, as long as defined regex pattern matches them correctly.