...
This however is a problem when template is part of some other non-related category. For example:
URL | Category | Template | Issue Description | |
---|---|---|---|---|
1 | platform/login/register.html | Home > Platform | /platform/login/register.tpl | Category was partially detected from template, but it's not related to template in any way. |
2 | modern/search-results.html | Modern > Search Results | /search-results.tpl | Template was partially detected from category and prevented category design to be used. |
Solution
- in the "\kRewriteUrlProcessor::_parsePhysicalTemplate" method:
- compare current $vars['t'] (populated from category parsing) and new $vars['t'] (populated from template parsing), but prior to adding "/index"
- if detected category path is completely within detected template, then patch $vars['m_cat_id'] in a way to emulate fact, that category wasn't detected at all
- if detected template is completely within detected category path, then don't change $vars['t'] and return false