From 1893bb477f303ddb3f0b722abe03313ecdc62238 Mon Sep 17 00:00:00 2001 From: 3m5/frohberg Date: Wed, 13 Mar 2024 16:27:03 +0100 Subject: [PATCH 1/2] Fix reloading iframe content Remove origin from Iframe url --- Classes/Fusion/Helper/NodeInfoHelper.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Classes/Fusion/Helper/NodeInfoHelper.php b/Classes/Fusion/Helper/NodeInfoHelper.php index fc4b2390ab..1c16f1fc1c 100644 --- a/Classes/Fusion/Helper/NodeInfoHelper.php +++ b/Classes/Fusion/Helper/NodeInfoHelper.php @@ -344,7 +344,10 @@ public function uri(Node|NodeAddress $nodeAddress, ActionRequest $actionRequest) $nodeAddressFactory = NodeAddressFactory::create($contentRepository); $nodeAddress = $nodeAddressFactory->createFromNode($nodeAddress); } - return (string)NodeUriBuilder::fromRequest($actionRequest)->uriFor($nodeAddress); + $uriBuilder = new UriBuilder(); + $uriBuilder->setRequest($actionRequest); + $uriBuilder->setCreateAbsoluteUri(true); + return (string)NodeUriBuilder::fromUriBuilder($uriBuilder)->uriFor($nodeAddress); } public function previewUri(Node $node, ActionRequest $actionRequest): string From 4cb1428f072399ba392bb5cb12dbadccee4d4bfd Mon Sep 17 00:00:00 2001 From: 3m5/frohberg Date: Fri, 26 Apr 2024 18:06:41 +0200 Subject: [PATCH 2/2] BUGFIX: Create absolute URI in NodeInfoHelper.php for previewUri --- Classes/Fusion/Helper/NodeInfoHelper.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Classes/Fusion/Helper/NodeInfoHelper.php b/Classes/Fusion/Helper/NodeInfoHelper.php index 1c16f1fc1c..3e902cff3f 100644 --- a/Classes/Fusion/Helper/NodeInfoHelper.php +++ b/Classes/Fusion/Helper/NodeInfoHelper.php @@ -355,7 +355,11 @@ public function previewUri(Node $node, ActionRequest $actionRequest): string $contentRepository = $this->contentRepositoryRegistry->get($node->subgraphIdentity->contentRepositoryId); $nodeAddressFactory = NodeAddressFactory::create($contentRepository); $nodeAddress = $nodeAddressFactory->createFromNode($node); - return (string)NodeUriBuilder::fromRequest($actionRequest)->previewUriFor($nodeAddress); + + $uriBuilder = new UriBuilder(); + $uriBuilder->setRequest($actionRequest); + $uriBuilder->setCreateAbsoluteUri(true); + return (string)NodeUriBuilder::fromUriBuilder($uriBuilder)->previewUriFor($nodeAddress); } public function createRedirectToNode(Node $node, ActionRequest $actionRequest): string