Bug #15939 Clarification Requested

require_entry unusable if dynamic=yes, multi-entry 404 difficulties

Version: 2.2.2 Reporter: narration

This is an archived bug report. If you are experiencing a similar issue, upgrade to the latest release and if that does not solve the problem, submit a new bug report

This comes up in trying to get proper 404 handling with archives. You have a multi-entry page to list the archives, and want to 404 any bad urls fed to it. Strict URL is on. You have an if {no_results} handler. Dynamic is unset, equivalent yes.

If you set require_entry in the channel:entries tag, then your if no_results handler will fire whatever is in the url for the page.

This fail occurs with nothing in date code segments 3 or 4 for a full listing, or with proper values to limit to a year/month, or with improper values for these which I am trying to catch.

Further important point for 404s.  It may have been intended that dynamic segment reading alone handle whether or not year/month URL segments match entries. However, this does not properly work. Indeed, if an invalid month or numeric year is passed, if no_results fires.

But if a non-numeric segment_3 (bad url_name or year) is passed (i.e. 2007z or august), then _all_ entries are returned. Proper action would be that if no_results fires.

In other words, for now and potentially for 2.2 release, it’s not apparently possible to lock down to proper 404 handling for multi-entry pages (dynamic=“yes”).

Your judgement when this needs fixing.

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases