You are here

public function XmlSitemapGeneratorInterface::getPathAlias in XML sitemap 2.x

Same name and namespace in other branches
  1. 8 src/XmlSitemapGeneratorInterface.php \Drupal\xmlsitemap\XmlSitemapGeneratorInterface::getPathAlias()

Given an internal Drupal path, return the alias for the path.

This is similar to drupal_get_path_alias(), but designed to fetch all aliases at once so that only one database query is executed instead of severa or possibly thousands during sitemap generation.

Parameters

string $path: An internal Drupal path.

string $language: A language code to use when looking up the paths.

1 method overrides XmlSitemapGeneratorInterface::getPathAlias()
XmlSitemapGenerator::getPathAlias in src/XmlSitemapGenerator.php
Given an internal Drupal path, return the alias for the path.

File

src/XmlSitemapGeneratorInterface.php, line 22

Class

XmlSitemapGeneratorInterface
Provides an interface defining a XmlSitemapGenerator service.

Namespace

Drupal\xmlsitemap

Code

public function getPathAlias($path, $language);