Skip to content

Commit

Permalink
Fix configuration for forceAbsoluteUrl property
Browse files Browse the repository at this point in the history
  • Loading branch information
beatrycze-volk committed May 31, 2024
1 parent 5de709f commit 385e46d
Show file tree
Hide file tree
Showing 8 changed files with 19 additions and 11 deletions.
2 changes: 1 addition & 1 deletion Classes/Controller/AbstractController.php
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ protected function configureProxyUrl(string &$url): void
{
$this->uriBuilder->reset()
->setTargetPageUid($this->pageUid)
->setCreateAbsoluteUri(!empty($this->settings['general']['forceAbsoluteUrl']))
->setCreateAbsoluteUri(!empty($this->settings['forceAbsoluteUrl']))
->setArguments(
[
'eID' => 'tx_dlf_pageview_proxy',
Expand Down
2 changes: 1 addition & 1 deletion Classes/Controller/PageViewController.php
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ public function mainAction(): void
// Get the controls for the map.
$this->controls = explode(',', $this->settings['features']);

$this->view->assign('forceAbsoluteUrl', $this->settings['general']['forceAbsoluteUrl']);
$this->view->assign('forceAbsoluteUrl', $this->settings['forceAbsoluteUrl']);

$this->addViewerJS();

Expand Down
10 changes: 10 additions & 0 deletions Configuration/FlexForms/PageView.xml
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,16 @@
</config>
</TCEforms>
</settings.progressElementId>
<settings.forceAbsoluteUrl>
<TCEforms>
<exclude>1</exclude>
<label>LLL:EXT:dlf/Resources/Private/Language/locallang_be.xlf:plugins.pageview.flexform.forceAbsoluteUrl</label>
<config>
<type>check</type>
<default>0</default>
</config>
</TCEforms>
</settings.forceAbsoluteUrl>
<settings.useInternalProxy>
<TCEforms>
<exclude>1</exclude>
Expand Down
4 changes: 4 additions & 0 deletions Resources/Private/Language/de.locallang_be.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -373,6 +373,10 @@
<source><![CDATA[Zoom Panel]]></source>
<target><![CDATA[Zoom-Knöpfe]]></target>
</trans-unit>
<trans-unit id="plugins.pageview.flexform.forceAbsoluteUrl" approved="yes">
<target><![CDATA[Verwende nur absolute Links für Seiten und Ressourcen?: Wird nur in speziellen Multi-Domain-Umgebungen benötigt; erfordert einen voll qualifizierten Einstiegspunkt in der Seitenkonfiguration (Standard ist "FALSE")]]></target>
<source><![CDATA[Force all links to pages and resources to be absolute?: Only needed for some multi-domain environments; requires a fully qualified Entry Point in Site Configuration (default is "FALSE")]]></source>
</trans-unit>
<trans-unit id="plugins.pageview.flexform.magnifier" approved="yes">
<source><![CDATA[Activate magnifier]]></source>
<target><![CDATA[Lupenfunktion aktivieren]]></target>
Expand Down
4 changes: 0 additions & 4 deletions Resources/Private/Language/de.locallang_labels.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -641,10 +641,6 @@
<target>DLF User-Agent: (Standard ist "Kitodo.Presentation")</target>
<source>DLF User-Agent: (default is "Kitodo.Presentation")</source>
</trans-unit>
<trans-unit id="config.general.forceAbsoluteUrl">
<target>Verwende nur absolute Links für Seiten und Ressourcen?: Wird nur in speziellen Multi-Domain-Umgebungen benötigt; erfordert einen voll qualifizierten Einstiegspunkt in der Seitenkonfiguration (Standard ist "FALSE")</target>
<source>Force all links to pages and resources to be absolute?: Only needed for some multi-domain environments; requires a fully qualified Entry Point in Site Configuration (default is "FALSE")</source>
</trans-unit>
<trans-unit id="config.general.forceAbsoluteUrlHttps">
<target>Verwende HTTPS for absolute Links?: erfordert einen Einstiegspunkt mit "https://..." in der Seitenkonfiguration (Standard ist "FALSE")</target>
<source>Use HTTPS for absolute links?: requires a valid Entry Point with "https://..." in Site Configuration (default is "FALSE")</source>
Expand Down
3 changes: 3 additions & 0 deletions Resources/Private/Language/locallang_be.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -239,6 +239,9 @@
<trans-unit id="plugins.pageview.flexform.features.zoompanel">
<source><![CDATA[Zoom Panel]]></source>
</trans-unit>
<trans-unit id="plugins.pageview.flexform.forceAbsoluteUrl">
<source><![CDATA[Force all links to pages and resources to be absolute?: Only needed for some multi-domain environments; requires a fully qualified Entry Point in Site Configuration (default is "FALSE")]]></source>
</trans-unit>
<trans-unit id="plugins.pageview.flexform.magnifier">
<source><![CDATA[Activate magnifier]]></source>
</trans-unit>
Expand Down
3 changes: 0 additions & 3 deletions Resources/Private/Language/locallang_labels.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -482,9 +482,6 @@
<trans-unit id="config.general.userAgent">
<source>DLF User-Agent: (default is "Kitodo.Presentation")</source>
</trans-unit>
<trans-unit id="config.general.forceAbsoluteUrl">
<source>Force all links to pages and resources to be absolute?: Only needed for some multi-domain environments; requires a fully qualified Entry Point in Site Configuration (default is "FALSE")</source>
</trans-unit>
<trans-unit id="config.general.forceAbsoluteUrlHttps">
<source>Use HTTPS for absolute links?: requires a valid Entry Point with "https://..." in Site Configuration (default is "FALSE")</source>
</trans-unit>
Expand Down
2 changes: 0 additions & 2 deletions ext_conf_template.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
general.enableInternalProxy = 0
# cat=General; type=string; label=LLL:EXT:dlf/Resources/Private/Language/locallang_labels.xlf:config.general.userAgent
general.userAgent = Kitodo.Presentation
# cat=General; type=boolean; label=LLL:EXT:dlf/Resources/Private/Language/locallang_labels.xlf:config.general.forceAbsoluteUrl
general.forceAbsoluteUrl = 0
# cat=General; type=boolean; label=LLL:EXT:dlf/Resources/Private/Language/locallang_labels.xlf:config.general.forceAbsoluteUrlHttps
general.forceAbsoluteUrlHttps = 0
# cat=General; type=boolean; label=LLL:EXT:dlf/Resources/Private/Language/locallang_labels.xlf:config.general.caching
Expand Down

0 comments on commit 385e46d

Please sign in to comment.