Home / Admin / Append a Page to the Additional Pages Sitemap
Duplicate Snippet

Embed Snippet on Your Site

Append a Page to the Additional Pages Sitemap

This filter can be used to Append a Page to the Additional Pages Sitemap

20+
Code Preview
php
<?php
add_filter( 'aioseo_sitemap_additional_pages', 'aioseo_sitemap_add_additional_pages' );
function aioseo_sitemap_add_additional_pages( $pages ) {
	$pages[] = [
		'loc'        => 'https://example.com/additional-page',
		'lastmod'    => '2020-12-11 11:11',
		'changefreq' => 'always',
		'priority'   => (float) 1.0
	];
	return $pages;
}

Comments

Add a Comment