SitemapController final readonly class
Minn\Front\SitemapController · public/minn/src/Minn/Front/SitemapController.php · 65 lines
The sitemap index, its pages, and the two stylesheets, as the reference serves them: the request's sitemap variables stand in the main query and the sitemaps server answers at template_redirect (SitemapRequest), through every filter a plugin hooks, any provider it registers among them; what it does not print, the theme renders (a 404, or the page a stray address amounts to).
Constants and properties
| private | readonly Closure $notFound | Promoted from the constructor. |
| private | readonly Minn\Theme\MainQueryBridge $bridge | Promoted from the constructor. |
| private | readonly Closure $themed | Promoted from the constructor. |
Public
| new | __construct(Closure $notFound, Minn\Theme\MainQueryBridge $bridge, Closure $themed)# | |
| method | sitemapIndex(Minn\Http\Request $request): Minn\Http\ResponseGET /wp-sitemap.xml (public)# | The sitemap index. |
| method | sitemap(Minn\Http\Request $request, string $name, string $rest): Minn\Http\ResponseGET /wp-sitemap-{name:[a-z]+}-{rest:[a-z_0-9-]+}.xml (public)# | One sitemap page: a provider's name, its subtype when it has them, and the page. |
| method | sitemapStylesheet(Minn\Http\Request $request): Minn\Http\ResponseGET /wp-sitemap.xsl (public)# | The sitemap stylesheet. |
| method | sitemapIndexStylesheet(Minn\Http\Request $request): Minn\Http\ResponseGET /wp-sitemap-index.xsl (public)# | The sitemap index stylesheet. |
| method | queried(Minn\Http\Request $request): Minn\Http\Response# | The query form (?sitemap=, ?sitemap-stylesheet=) on the front page, with plugins loaded. |
Internals 1
Private and protected methods: how the class does its work. Not a contract; they change whenever the code is tidied.
| private | served(array $vars): Minn\Http\Response# | The reference's answer: what the sitemaps server printed, else the theme's page on the query as it stands (a 404 when the server made it one).
|
Nothing matches.