Commit d082775d authored by Pawel G's avatar Pawel G
Browse files

Alter API documentation to reflect API changes

parent 076bac0f
......@@ -18,9 +18,20 @@
* Array containing multilingual links generated for each path to be indexed.
function hook_simple_sitemap_links_alter(&$links) {
// Remove German links for all paths in the hreflang sitemap.
// Remove German URL for a certain path in the hreflang sitemap.
foreach($links as &$link) {
if ($link['path'] == 'node/1') {
// Remove 'loc' URL if it points to a german site.
if ($link['langcode'] == 'de') {
// If this 'loc' URL points to a non-german site, make sure to remove
// its german alternate URL.
else {
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment