Definition

drupal_get_path_alias($path)
drupal-4-6/includes/bootstrap.inc, line 374

Description

Given an internal Drupal path, return the alias set by the administrator.

Code

function drupal_get_path_alias($path) {
  if (($map = drupal_get_path_map()) && ($newpath = array_search($path, $map))) {
    return $newpath;
  }
  elseif (function_exists('conf_url_rewrite')) {
    return conf_url_rewrite($path, 'outgoing');
  }
  else {
    // No alias found. Return the normal path.
    return $path;
  }
}