JKB
JKB

Reputation: 510

TYPO3 v10 - absolute links - config.absRefPrefix dead?

How to tell TYPO3 v10 (globally) to generate absolute links in frontend? config.absRefPrefix doesn't seem to work any longer. Also, using absolute urls as base in site configuration doesn't have any effect. Still relative links in frontend.

EDIT: config.absRefPrefix seems to work for embedded resources (script, img etc.) but not for usually generated hyperlinks (MenuProcessor, RTE links etc.). Do i really need to set option absolute=1 for all my links generated by view helpers and configure RTE processing to generate absolute links? Thought that's why the global option "absRefPrefix" exists...

Upvotes: 0

Views: 1316

Answers (2)

Peter Kraume
Peter Kraume

Reputation: 3747

This problem already exists since TYPO3 v9. There is a ticket in the bug tracker regarding this issue. I assume that in TYPO3 v12 config. absRefPrefix might be removed completely.

In the ticket comments you can find a number of hints, how to implement absolute links in various places:

  • use (NO/ACT/...).stdWrap.typolink.forceAbsoluteUrl = 1 for HMENU
  • for links in the CKEditor RTE this config make every link absolute:
    lib.parseFunc_RTE.tags.a.typolink {
      forceAbsoluteUrl = 1
      forceAbsoluteUrl.scheme = https
    }
    
  • if you want to globally rewrite all links to absolute links, you can implement the middleware mentioned in the ticket.

Upvotes: 1

Related Questions