aioseo_sitemap_additional_pages

aioseo_sitemap_additional_pages

Appears in: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Hook Type: filter

See hook in core

Displaying hooks found in version: all-in-one-seo-pack.4.7.5.1

apply_filters('aioseo_sitemap_additional_pages') is found 4 times:

  • /app/Common/Sitemap/Content.php line 466
    			array_unshift( $entries, $homepageEntry );
    		}
    
    		if ( aioseo()->options->sitemap->general->additionalPages->enable ) {
    			$entries = apply_filters( 'aioseo_sitemap_additional_pages', $entries );
    		}
    
    		if ( empty( $entries ) ) {
    			return [];
    		}
    
    
  • /app/Common/Sitemap/File.php line 77
    			}
    		}
    
    		$postTypes       = aioseo()->sitemap->helpers->includedPostTypes();
    		$additionalPages = apply_filters( 'aioseo_sitemap_additional_pages', $additionalPages );
    
    		if (
    			'posts' === get_option( 'show_on_front' ) ||
    			count( $additionalPages ) ||
    			! in_array( 'page', $postTypes, true )
    		) {
    
  • /app/Common/Sitemap/Helpers.php line 129
    			$pages[] = strtotime( $additionalPage->lastModified );
    		}
    
    		if ( empty( $pages ) ) {
    			$additionalPages = apply_filters( 'aioseo_sitemap_additional_pages', [] );
    			if ( empty( $additionalPages ) ) {
    				return false;
    			}
    
    			$lastModified = 0;
    			$timestamp    = time();
    
  • /app/Common/Sitemap/Root.php line 176
    			];
    		}
    
    		if ( aioseo()->options->sitemap->general->additionalPages->enable ) {
    			$entries = apply_filters( 'aioseo_sitemap_additional_pages', $entries );
    		}
    
    		$postTypes             = aioseo()->sitemap->helpers->includedPostTypes();
    		$shouldIncludeHomepage = 'posts' === get_option( 'show_on_front' ) || ! in_array( 'page', $postTypes, true );
    		if ( ! $shouldIncludeHomepage && ! count( $entries ) ) {
    			return [];