Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions Classes/Controller/MultiViewController.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
namespace Kitodo\Dlf\Controller;

use Psr\Http\Message\ResponseInterface;
use TYPO3\CMS\Core\Utility\GeneralUtility;
use Ubl\Iiif\Presentation\Common\Model\Resources\CanvasInterface;
use Ubl\Iiif\Presentation\Common\Model\Resources\ManifestInterface;
use Ubl\Iiif\Presentation\Common\Vocabulary\Motivation;
Expand Down Expand Up @@ -48,6 +49,12 @@ public function mainAction(): ResponseInterface

$page = $this->requestData['page'] ?? 0;

$currentUrl = GeneralUtility::getIndpEnv('TYPO3_REQUEST_URL');
$parts = parse_url($currentUrl);
$currentPath = $parts['path'] ?? '/';

$this->view->assign('path', $currentPath);

$this->view->assign('forceAbsoluteUrl', $this->extConf['general']['forceAbsoluteUrl'] ?? 0);
$this->view->assign('docId', $this->requestData['id']);
$this->view->assign('page', $page);
Expand Down
4 changes: 2 additions & 2 deletions Resources/Private/Templates/MultiView/Main.html
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
</div>
<div class="measureFwds">
<span class="next">
<a href="#" data-page-control-selector=".measureFwds .next a" ></f:translate key="nextMeasure" /></a>
<a href="#" data-page-control-selector=".measureFwds .next a" ><f:translate key="nextMeasure" /></a>
</span>
</div>
</div>
Expand All @@ -44,7 +44,7 @@
<div class="grid-stack-item {f:if(condition: '{document.sourceKey} >= 0', then: 'grid-stack-item-highlighted')}" gs-w="6" gs-h="6" gs-id="{iterator.index}" >
<div class="grid-stack-item-content" style="overflow: hidden">
<div class="loader" ><div class="spinner"></div></div>
<iframe src="/viewer?tx_dlf%5Bid%5D={document.encodedUrl}&tx_dlf%5Bpage%5D={document.page}&tx_dlf%5Bmultiviewembedded%5D=1" width="100%" height="100%"></iframe>
<iframe src="{path}?tx_dlf%5Bid%5D={document.encodedUrl}&tx_dlf%5Bpage%5D={document.page}&tx_dlf%5Bmultiviewembedded%5D=1" width="100%" height="100%"></iframe>
</div>
<div class="gridstack-dragging-handle" title="{f:translate(key: 'multiview.dragging_label', extensionName: 'dfgviewer')}"></div>
<f:if condition="{document.sourceKey} >= 0">
Expand Down
Loading