class Sitemap (View source)

The Sitemap class handles the generating process for a site's sitemap.xml.

Methods

__construct(array $collection)

The constructor verifies, whether sitemap.xml can be written and initiates the generating process.

generate(array $collection, string $sitemap)

Generate the XML for the sitemap and write sitemap.xml.

Details

__construct(array $collection)

The constructor verifies, whether sitemap.xml can be written and initiates the generating process.

Parameters

array $collection

private generate(array $collection, string $sitemap)

Generate the XML for the sitemap and write sitemap.xml.

Parameters

array $collection
string $sitemap