Support » Plugin: SEOPress, on-site SEO » Attachment Sitemap is empty

  • Resolved Tim Reeves


    Hi SEOPress-Team,

    I really love the plugin, just discovered it a couple of days ago and am writing a blog article about SEO in which I will recommend it. What I especially like is that the word “competition” does not appear on your page at

    But right now, I need a little happiness from your happiness engineer 🙂

    I’m working on a clients website – The Syrian Heritage Archive Project, a great team, digitally saving as much of the (partially destroyed) Syrian Heritage as they can. So a major part of their work is with pictures. They have a gallery page on their website, which infinitely scrolls thousands of pictures, allowing you to click on any one and go to its attachment page. Here is a typical attachment page – as you can see, it has been extended to show a lot more than usual, so it is imho worth indexing them.

    I have activated Media attachments for the XML sitemap, and have deactivated the redirects to file or post parent in the advanced settings. However, I’m still seeing an empty attachment sitemap (linked up above). I have no explanation for this, but would be very happy to see it working.

    BTW: I’m using W3TC and I have manually adjusted its parameters to not cache any of your sitemaps. For Yoast and Rank Math the default settings of W3TC do work (sitemap_index.xml) – but not for AIOSEO (sitemap.xml) or SEOPress (sitemaps.xml), all of which caused me some grief. Would it be possible to add an option – or quietly change the new default address – to use sitemap_index.xml, which seems to be a more generally adopted name? I do understand that this may not be easy – as an avid Nginx user…

    Cheers and again many thanks!


    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter Tim Reeves


    To add some more to that:

    • The website uses WPML for english, german and arabic
    • The gallery is generated dynamically by a plugin, so most images are not directly referenced on pages
    • However, some of them are, on the “Stories” pages

    Hope this helps…

    Plugin Author Benjamin Denis


    Hi Tim,

    thank you for your feedback.

    We have a guide to use W3TC with SEOPress here:

    Can you take a screenshot of your general XML sitemaps settings please?

    Thank you!

    • This reply was modified 1 month, 3 weeks ago by Benjamin Denis. Reason: typo
    Thread Starter Tim Reeves


    Hi @rainbowgeek

    many thanks for your reply and so sorry not to have been able to reply earlier.

    I use Nginx and have these rules in place:

    location ~ ([^/]*)sitemap(.*)\.x(m|s)l$ {
    rewrite ^.*/sitemaps\.xml$ /index.php?seopress_sitemap=1 last;
    rewrite ^.*/sitemaps/news.xml$ /index.php?seopress_news=$1 last;
    rewrite ^.*/sitemaps/video.xml$ /index.php?seopress_video=$1 last;
    rewrite ^.*/sitemaps/author.xml$ /index.php?seopress_author=$1 last;
    rewrite ^.*/sitemaps_xsl\.xsl$ /index.php?seopress_sitemap_xsl=1 last;
    rewrite ^.*/sitemaps/([^/]+?)-sitemap([0-9]+)?.xml$ /index.php?seopress_cpt=$1&seopress_paged=$2 last;

    The sitemap is at:

    It links to 5 sub-sitemaps; posts, pages and categories are as expected, post-tags is empty as expected (no tags defined). But…

    is still empty. We use WPML and import the images ourselves (from easydb, via a non-trivial own importer plugin); and we also use the “Media Library Assistant” plugin. So I must admit, it’s not exactly a simple or uncomplicated setup. But the images (mainly of destroyed heritage sites in Syria) are of cultural importance and we really need them to be indexed – by “them” meaning the image pages, which provide more info, not simply the image file itself.

    I made a screenshot of my Sitemap settings page, but see no way to upload here.

    In “General” the option “Enable XML Image Sitemaps” is selected. Under Post types the type “Media [attachment]” is checked (despite your advice) as in our special case that’s exactly what we need. The theme in use is a custimsed version of Twenty Nineteen, and uses the standard path “images.php” as the file to use to display attachments as own pages.

    Since you advise against using the option which we need, maybe it hasn’t been tested so much? If you need confidential data to debug the issue, read on:

    I’ll be buying the Pro version now, I think I don’t need it for my own purposes, but you guys have earned it many times over! I assume you will have a paid support page where I can upload confidential access data.



    Plugin Author Benjamin Denis


    Hi Tim,

    this issue will be solved in our next update.


Viewing 4 replies - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.