Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sitemap: Wrong XHTML namespace declaration? (Multilang Setup) #14

Closed
moefuerst opened this issue Oct 17, 2022 · 2 comments
Closed

Sitemap: Wrong XHTML namespace declaration? (Multilang Setup) #14

moefuerst opened this issue Oct 17, 2022 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@moefuerst
Copy link

I am testing this plugin in a multilang setup and got a complaint from the Google Search Console about a wrong namespace declaration in the Sitemap.

I think the issue is the XHTML namespace declaration in line 34 of src/Sitemap.php:

Currently:

$root->setAttributeNS('http://www.w3.org/2000/xmlns/', 'xmlns:xhtml', 'http://www.w3.org/1999/xlink');

Should be

$root->setAttributeNS('http://www.w3.org/2000/xmlns/', 'xmlns:xhtml', 'http://www.w3.org/1999/xhtml');

After I corrected this, the map was accepted as correct.

Reference: developers.google.com/search/docs/specialty/international/localized-versions#sitemap.

@fabianmichael
Copy link
Owner

@moefuerst Thanks for the hint. Fixed it and created a new release. :-)

@fabianmichael fabianmichael added the bug Something isn't working label Oct 17, 2022
@fabianmichael fabianmichael self-assigned this Oct 17, 2022
@moefuerst
Copy link
Author

@fabianmichael Thanks for the fast fix and sorry I didn't have a PR ready! Great plugin, not only because of it's functionality but also as an educational resource for Kirby plugin development…

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants