Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. Drupal.php

function Drupal::root

Gets the app root.

Return value

string

15 calls to Drupal::root()
DbCommandBase::getDatabaseConnection in core/lib/Drupal/Core/Command/DbCommandBase.php
Parse input options decide on a database.
drupal_check_profile in core/includes/install.inc
Checks an installation profile's requirements.
drupal_verify_profile in core/includes/install.inc
Verifies that all dependencies are met for a given installation profile.
ExtensionInstallStorage::getAllFolders in core/lib/Drupal/Core/Config/ExtensionInstallStorage.php
Returns a map of all config object names and their folders.
InstallStorage::getAllFolders in core/lib/Drupal/Core/Config/InstallStorage.php
Returns a map of all config object names and their folders.

... See full list

File

core/lib/Drupal.php, line 219

Class

Drupal
Static Service Container wrapper.

Code

public static function root() {
    return static::getContainer()->getParameter('app.root');
}
RSS feed
Powered by Drupal