1
0
mirror of https://github.com/typemill/typemill.git synced 2025-08-06 22:26:32 +02:00

Version 1.4.2 Fix htaccess for pages with name like system folders

This commit is contained in:
trendschau
2020-11-25 10:36:41 +01:00
parent 5a20be8322
commit 7198b80d4b
2 changed files with 50 additions and 20 deletions

View File

@@ -23,7 +23,8 @@ use Typemill\Extensions\ParsedownExtension;
class PageController extends Controller
{
public function index($request, $response, $args)
{
{
/* Initiate Variables */
$structure = false;
$contentHTML = false;
@@ -115,9 +116,9 @@ class PageController extends Controller
}
else
{
# get the request url
$urlRel = $uri->getBasePath() . '/' . $args['params'];
# get the request url, trim args so physical folders have no trailing slash
$urlRel = $uri->getBasePath() . '/' . trim($args['params'], "/");
# find the url in the content-item-tree and return the item-object for the file
# important to use the structure here so it is found, even if the item is hidden.
$item = Folder::getItemForUrl($structure, $urlRel, $uri->getBasePath());