[wp-trac] [WordPress Trac] #56671: Sitemaps not working with almost pretty permalinks
WordPress Trac
noreply at wordpress.org
Tue Sep 27 21:21:54 UTC 2022
#56671: Sitemaps not working with almost pretty permalinks
--------------------------+-----------------------------
Reporter: Chouby | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Sitemaps | Version: 5.5
Severity: normal | Keywords:
Focuses: |
--------------------------+-----------------------------
As the documentation states, WordPress supports 3 types of permalinks:
https://wordpress.org/support/article/using-permalinks/#permalink-types-1.
- Plain per(malinks: `https://example.org/?sitemap=index`
- Pretty permalinks: `https://example.org/wp-sitemap.xml`
- Almost pretty permalinks: `https://example.org/index.php/wp-sitemap.xml`
The 3rd solution is provided for servers with rewrite engine off.
The first 2 options are working as expected, not the third one.
To reproduce:
Tested on an Apache server:
- Select `index.php/%postname%/` in permalinks settings.
- Delete the file `.htaccess` (this deactivates rewrite engine).
- Check that you can navigate on frontend, visiting posts, pages,
categories, etc... with urls all including `index.php`.
- Attempt to visit `https://example.org/index.php/wp-sitemap.xml` (which I
expect to be the sitemap index).
=> You are redirected to `https://example.org/wp-sitemap.xml` which is a
server 404 page.
You are also redirected to the same 404 if you attempt to visit
`https://example.org/?sitemap=index`
--
Ticket URL: <https://core.trac.wordpress.org/ticket/56671>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list