Skip to main content

Add i18nsitemap to your INSTALLED_APPS

In your Sitemap class who supports i18n inherit from i18nsitemap.I18nSitemap instead from django.

Set i18n = True

That’s it. And there is no problem on using I18nSitemap on any Sitemap class, no needs to add or remove anything.

Here it follows an example

class BlogSitemap(I18nSitemap):
    changefreq = "never"
    priority = 0.5
    i18n = True

    def items(self):
        return Entry.objects.filter(is_draft=False)

    def lastmod(self, obj):
        return obj.pub_date

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

django-i18n-sitemap-0.1.tar.gz (2.3 kB view details)

Uploaded Source

File details

Details for the file django-i18n-sitemap-0.1.tar.gz.

File metadata

File hashes

Hashes for django-i18n-sitemap-0.1.tar.gz
Algorithm Hash digest
SHA256 f15be064f30d6527f46295d4abb330cb80b751b0887cabb14e903214b2d1a47b
MD5 5de8620ef689b48dc3c76b3dfa6ed6d4
BLAKE2b-256 d6fe8842dc861fad4e6dc4083b5a0bfc899c882cd55639e7876223d294ba0ad1

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.1 This release

1 file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page