Skip to content
Snippets Groups Projects
Select Git revision
  • 93c47c16c23888dcdba6935ef1d786c8166d558e
  • master default protected
  • 2.0.0-alpha-11
  • 2.0.0-alpha-10
  • 2.0.0-alpha-9
  • 2.0.0-alpha-8
  • 2.0.0-alpha-7
  • 2.0.0-alpha-6
  • 2.0.0-alpha-5
  • 2.0.0-alpha-4
  • 2.0.0-alpha-3
  • 2.0.0-alpha-2
  • 2.0.0-alpha-1
  • 1.8.0
  • 1.7.0
  • 1.6.4
  • 1.6.3
  • 1.6.2
  • 1.6.1
  • 1.6.0
  • 1.5.5
  • 1.5.4
22 results

pagination.mustache

Blame
  • Forked from TO / Weby / ui-styleguide
    Source project has a limited visibility.
    views.py 493 B
    from django.http import HttpResponse
    from wagtail.models import Site
    
    
    def page_not_found(request, exception=None):
        try:
            site = Site.find_for_request(request)
            root_page = site.root_page.specific
        except:
            root_page = None
    
        if root_page and hasattr(root_page, "get_404_response"):
            return root_page.get_404_response(request)
    
        return HttpResponse(
            "<h1>Stránka nenalezena</h1><a href='/'>pokračovat na úvod</a>",
            status=404,
        )