Получаем URL просматриваемой страницы в Drupal 7


13:51, 21/03/2018
// https://api.drupal.org/api/drupal/includes!path.inc/function/current_path/7
echo $GLOBALS['base_url'];       # http://m5-web.com
echo base_path();        # /
echo request_uri();      # /blog/71
echo request_path();     # blog/71
echo current_path();     # node/71
echo drupal_get_path_alias(current_path());  # blog/71
echo request_path();     # en/blog/71


Комментарии