Drupal investigation

example.sites.php 2.3KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. <?php
  2. /**
  3. * @file
  4. * Configuration file for multi-site support and directory aliasing feature.
  5. *
  6. * This file is required for multi-site support and also allows you to define a
  7. * set of aliases that map hostnames, ports, and pathnames to configuration
  8. * directories in the sites directory. These aliases are loaded prior to
  9. * scanning for directories, and they are exempt from the normal discovery
  10. * rules. See default.settings.php to view how Drupal discovers the
  11. * configuration directory when no alias is found.
  12. *
  13. * Aliases are useful on development servers, where the domain name may not be
  14. * the same as the domain of the live server. Since Drupal stores file paths in
  15. * the database (files, system table, etc.) this will ensure the paths are
  16. * correct when the site is deployed to a live server.
  17. *
  18. * To activate this feature, copy and rename it such that its path plus
  19. * filename is 'sites/sites.php'.
  20. *
  21. * Aliases are defined in an associative array named $sites. The array is
  22. * written in the format: '<port>.<domain>.<path>' => 'directory'. As an
  23. * example, to map https://www.drupal.org:8080/mysite/test to the configuration
  24. * directory sites/example.com, the array should be defined as:
  25. * @code
  26. * $sites = array(
  27. * '8080.www.drupal.org.mysite.test' => 'example.com',
  28. * );
  29. * @endcode
  30. * The URL, https://www.drupal.org:8080/mysite/test/, could be a symbolic link
  31. * or an Apache Alias directive that points to the Drupal root containing
  32. * index.php. An alias could also be created for a subdomain. See the
  33. * @link https://www.drupal.org/documentation/install online Drupal installation guide @endlink
  34. * for more information on setting up domains, subdomains, and subdirectories.
  35. *
  36. * The following examples look for a site configuration in sites/example.com:
  37. * @code
  38. * URL: http://dev.drupal.org
  39. * $sites['dev.drupal.org'] = 'example.com';
  40. *
  41. * URL: http://localhost/example
  42. * $sites['localhost.example'] = 'example.com';
  43. *
  44. * URL: http://localhost:8080/example
  45. * $sites['8080.localhost.example'] = 'example.com';
  46. *
  47. * URL: https://www.drupal.org:8080/mysite/test/
  48. * $sites['8080.www.drupal.org.mysite.test'] = 'example.com';
  49. * @endcode
  50. *
  51. * @see default.settings.php
  52. * @see \Drupal\Core\DrupalKernel::getSitePath()
  53. * @see https://www.drupal.org/documentation/install/multi-site
  54. */