clickstorm / cs_seo

[clickstorm] SEO
Other
33 stars 49 forks source link

sitemap.xml: empty news-sitemap is generated also if no news entrys are present and news-extension is installed but not configured in tx_csseo configuration #206

Closed tobiasgraeber closed 5 years ago

tobiasgraeber commented 6 years ago

even if you dont have any news in your system yet and also if you dont configured "extensions" news in your ts there is a link generated in the sitemap.xml like this:

http://domain.local/?type=655&tx_csseo_view=extension&ext=news

Below this url, youl find an empty sitemap like this:

<urlset><url><loc/></url><url><loc/></url><url><loc/></url><url><loc/></url></urlset>

Suggestion:

tobiasgraeber commented 6 years ago

Okay, after removing the TS-include for the news, this does not happen. Anyway i would suggest an additional check might be a good idea?

Same for languageUids - for example if you configure id 0 and 1 but only have a default language or (sometimes later) disable the additional language 1 (and forget to adjust the cs_seo ts-configuration) than this will lead to generating 2times the sitemap vor id 0 in /sitemap.xml or an "empty" second one...

...maybe just an improvement but i think additional internal checks "if there really is a language/news with de uids defined in ts before generating a sitemap" - would make this module much more reliable / save

?!

mhirdes commented 6 years ago

Mmhh. I am with u, but then we have to check in the sitemap index view for every sub sitemap if there are records. Furthermore in cs_seo v4 the sitemap.xml generation is removed, because you can do this within the TYPO3 v9 LTS core. Can u live with the current solution until v9?

tobiasgraeber commented 6 years ago

Yes :) Thanks for your work! Regarding the other issues ill come back these days after testing again ;-)