You are here

function hook_simple_sitemap_index_attributes_alter in Simple XML sitemap 8.2

Same name and namespace in other branches
  1. 8.3 simple_sitemap.api.php \hook_simple_sitemap_index_attributes_alter()
  2. 4.x simple_sitemap.api.php \hook_simple_sitemap_index_attributes_alter()

Alters attributes of the sitemap index shortly before XML document generation. Attributes can be added, changed and removed.

Parameters

array &$index_attributes:

1 invocation of hook_simple_sitemap_index_attributes_alter()
SitemapGenerator::generateSitemapIndex in src/SitemapGenerator.php
Generates and returns the sitemap index for all sitemap chunks.

File

./simple_sitemap.api.php, line 89
Hooks provided by the Simple XML sitemap module.

Code

function hook_simple_sitemap_index_attributes_alter(array &$index_attributes) {

  // Add some attribute to the sitemap index.
  $index_attributes['name'] = 'value';
}