Skip to content

TypeError in LinkFactory::createUri() when info_window_content contains an internal page link (TYPO3 14) #379

Description

@terminal8-nz

Environment

  • TYPO3: 14.3.7
  • maps2: 13.0.1
  • PHP: 8.5

Steps to reproduce

  1. Create a POI collection record with a marker/route/etc.
  2. In the "Info Window Content" RTE field, insert an internal page link (e.g. via the standard RTE link browser → "Page").
  3. Render the map on the frontend and click on that marker.

Expected behavior
The info window opens and shows the content, including a working link to the internal page.

Actual behavior
The AJAX request to GetInfoWindowContentMiddleware fails. PHP logs:
PHP Warning: Undefined global variable $TYPO3_REQUEST in vendor/typo3/cms-frontend/Classes/Typolink/LinkFactory.php line 130

followed by a fatal TypeError, since ContentObjectRenderer::setRequest() is typed as non-nullable (ServerRequestInterface $request).

Thanks for having a look! 😊

Activity

  1. sfroemkenjw commented on Oct 1, 2026

    @sfroemkenjw
    Contributor

    Hi @terminal8-nz,

    thanks for your report and the detailed description.

    The clean solution would be to switch the info window template from f:transform.html to f:format.html. But that changes the rendered output for existing installations. That's a breaking change and not possible in a bugfix release. I will have another look at it with the next major version for TYPO3 15.

    For now I have added a small workaround: maps2 sets the TYPO3 request (TYPO3_REQUEST) itself while rendering the info window content. With that, internal page links work again.

    The fix is in #380 and version 13.1.1 is released.

    Have fun with maps2!

    Stefan

  2. terminal8-nz commented on Oct 6, 2026

    @terminal8-nz
    Author

    Thanks for the fix! 💐

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions