function drupal_get_path

7 common.inc drupal_get_path($type, $name)

Returns the path to a system item (module, theme, etc.).

Parameters

$type: The type of the item (i.e. theme, theme_engine, module, profile).

$name: The name of the item for which the path is requested.

Return value

The path to the requested item.

147 calls to drupal_get_path()
AggregatorTestCase::getAtomSample in modules/aggregator/aggregator.test
AggregatorTestCase::getRSS091Sample in modules/aggregator/aggregator.test
aggregator_test_feed in modules/aggregator/tests/aggregator_test.module
Page callback. Generates a test feed and simulates last-modified and etags.
AJAXFrameworkTestCase::testLazyLoad in modules/simpletest/tests/ajax.test
Test that new JavaScript and CSS files added during an AJAX request are returned.
ajax_forms_test_lazy_load_form_submit in modules/simpletest/tests/ajax_forms_test.module
Form submit handler: Adds JavaScript and CSS that wasn't on the original form.

... See full list

1 string reference to 'drupal_get_path'
module_load_include in includes/module.inc
Loads a module include file.

File

includes/common.inc, line 2792
Common functions that many Drupal modules will need to reference.

Code

function drupal_get_path($type, $name) {
  return dirname(drupal_get_filename($type, $name));
}