page_is_active:
The advantage of page_is_active compared to the previous tags is that it also nows how to handle page pretenders.If entry is a page pretender, the template tag returns True if the current path starts with the page pretender’s path.
if isinstance(page, PagePretender): if path is None: path = context['request'].path_info return page.get_absolute_url().startswith(path)