Answers for "drupal 8 get module path"

1

drupal 8 get module path

// Module path
$module_handler = \Drupal::service('module_handler');
$module_path = $module_handler->getModule('my_module')->getPath();
Posted by: Guest on September-17-2020

Browse Popular Code Answers by Language