No sitemap
-
Hi,
As suggested by Choubi in this topic: https://www.ads-software.com/support/topic/sitemap-and-polylang?replies=2 I tried the XML Sitemap Feed plugin, and it’s just not producing anything.
Even the ?feed=sitemap gives me a 503 error while the actual sitemap.xml returns a 404.
I checked -quikly- in the source of XML SF plugin and I found traces of a polylang function. Is it really working?Cheers,
Nicolas.
-
See anything in the log files? Do you have a link so I can take a look?
My cPanel and my WP have no logs (empty) and unfortunately I cannot provide you a link, sorry. I deactivated all my plugins and it’s still not working, producing the same 503 error.
Is there anywhere else I could look for a solution?Cheers,
Did you also disable Polylang to test for a minute? Is your site very big? It might be that PHP is running out of memory… Or security settings are tight an the attempt to increase memory is running into an error. But then the whole WP admin would too… Is it a ‘regular’ Apache server or are you on Windows?
I must say, I have no idea without more info. You might try the Development version on https://www.ads-software.com/extend/plugins/xml-sitemap-feed/developers/ which has been tested and works but you will see unfinished dummy options (testing stage) on the Privacy admin page. These are harmless and will be replaced by actual working options in the stable release. But more importantly, the main single sitemap will be replaced by a sitemap index with several subsequent sitemaps per post type and taxonomy type. These are working sitemaps and I wonder if that version runs into the same issue on your server.
Ok, I think I know a bit why this happend although it’s still not 100% fixed.
This happened because I blocked the search engines (as I was still working on the website content), now the robots.txt has the following:# XML Sitemap Feed 3.9.2 (https://status301.net/wordpress-plugins/xml-sitemap-feed/) Sitemap: https://www.website.com/sitemap.xml?lang=en Sitemap: https://www.website.com/sitemap.xml?lang=fr Sitemap: https://www.website.com/sitemap.xml?lang=es Sitemap: https://www.website.com/sitemap-news.xml?lang=en Sitemap: https://www.website.com/sitemap-news.xml?lang=fr Sitemap: https://www.website.com/sitemap-news.xml?lang=es User-agent: * Disallow: /wp-admin/ Disallow: /wp-includes/
But none of those links is working, giving me a 404 error.
Thehttps://www.website.com/?feed=sitemap
url is working now but not as expected as it is showing all the languages pages. If I put the following urlhttps://www.website.com/?feed=sitemap&lang=en
it’s working as expected though! Maybe we/I should just amend the way robots.txt is created on the fly?Your development version is not working either unfortunately.
Oh and btw, my website’s hosted on a shared server on hostgator and I’ve already installed numerous wordpress on my account without any errors linked to the actual server configuration (I think it’s a “standard” LAMP environment).
Ah, yes… Didn’t think about that that one because your server responds with a status 503 “Service unavailable” instead of just letting WordPress handle the request, which would return a 404.
Setting a site to private will effectively disable the sitemap. Seeing as the
?feed=sitemap
URL is working, it looks like you also have disabled pretty permalinks. Correct?No I didn’t (it’s just
/sample-post/
), but regenerating them fixed the issue!Thanks,
Nicolas.Oh, by the way, the Polylang code in the plugin is stricktly speaking not necessary since the sitemap protocol does not need URLs to pages in different languages to go in a separate sitemaps… Polylang behaves in such a ‘natural’ way that there is no real need for extra code like the other multi-language plugins (as far as I tested) need.
The development release does not separate languages any more when using Polylang and XML Sitemap Feeds together. See for instance https://status301.net/sitemap.xml
Oh, good to know.
So you mean it’s only happening because it’s the development version? That won’t be the case in the next release then? (or am I totally wrong here?)
No I didn’t (it’s just /sample-post/), but regenerating them fixed the issue!
Thanks for letting me know… I’ll try to fix the need to manually regenerate permalinks after switching the site from private to public mode.
So you mean it’s only happening because it’s the development version?
To what that is happening are your referring?
No worries.
I was refering to the only one sitemap in the dev version. It’s only generating one sitemap instead of one per language, unless I misunderstood what you meant earlier and this is a feature? (not a bug…)
The latest dev version (you might need to reinstall) does one sitemap index on sitemap.xml and — on a regular install — four subsequent sitemaps: posts, pages, categories and tags… And indeed no separation into different languages.
Since Polylang creates different posts, pages, tags and categories per language, and so have different URLs, there is no need to separate them. The sitemap protocol does not require it either.
Polylang is perfect that way ??
And custom types as well I guess?
I thought that because you have different languages it meant different sitemaps as technically speaking, a page in French should not be linked to an English one.
And custom types as well I guess?
Yes.
…technically speaking, a page in French should not be linked to an English one.
Technically speaking there are no pages linked at all. The URLs are just there in the same sitemap but that does not ‘link’ them. Google and other search engines will just visit these pages without any ‘prejudice’ (initially even disregarding the priority value) and will learn each page’s language from the source html tags and index them appropriately.
It is only the Google News sitemap protocol that requires a language tag to be set in the news sitemap. The standard XML Sitemap protocol does not know such a tag, nor does is require different language pages to be referenced in different sitemaps.
Don’t worry, your site will be indexed correctly ??
Yes that’s very true actually, it’s just I was thinking -wrongly- that the sitemap would sort of link them because they show up in the same sitemap ??
Thanks for the explanation anyways!
- The topic ‘No sitemap’ is closed to new replies.