In components/com_content/router.php, the following condition (line 47) does not remove the layout from the query :
// are we dealing with an article or category that is attached to a menu item? if (($menuItem instanceof stdClass) && $menuItem->query['view'] == $query['view'] && isset($query['id']) && $menuItem->query['id'] == intval($query['id'])) { unset($query['view']); if (isset($query['catid'])) { unset($query['catid']); } unset($query['id']); return $segments; }
this may result in links like index.php/extensions?layout=blog, where the original link was something like index.php?option=com_content&view=category&layout=blog&id=20&Itemid=527
Easily fixed by removing the layout from the $query, eg:
// are we dealing with an article or category that is attached to a menu item? if (($menuItem instanceof stdClass) && $menuItem->query['view'] == $query['view'] && isset($query['id']) && $menuItem->query['id'] == intval($query['id'])) { unset($query['view']); if (isset($query['catid'])) { unset($query['catid']); } if (isset($query['layout'])) { unset($query['layout']); } unset($query['id']); return $segments; }
Labels |
Added:
?
|
||
Build | ⇒ | staging |
Re-submitted with pull request