如何避免 Typo3 自动将地址呈现为链接?

问题描述 投票:0回答:1

我在 Typo3 的“页面”视图中输入了以下“格式化”文本:

$ curl -s https://www.hello.ch/repo.gpg

在同一视图中有以下“来源”:

<pre>$ curl -s https://www.hello.ch/repo.gpg</pre>

这个源正是我在渲染中所期望的,但它被渲染成:

<pre>$ curl -s <a href="https://www.hello.ch/repo.gpg" target="_blank">www.hello.ch/repo.gpg</a></pre>

我只想呈现非链接版本:

<pre>$ curl -s https://www.hello.ch/repo.gpg</pre>

所以它不会在最终的 HTML 中显示链接。我如何实现这一目标?

我设法避免自动渲染的唯一方法是在“https”之前添加一些额外的字符,例如:

<pre>$ curl -s _https://www.hello.ch/repo.gpg</pre>

但是下划线当然会使说明错误。

typo3 typo3-9.x
1个回答
0
投票

您可以调整

lib.parseFunc
lib.parseFunc_RTE
的行为以获得您想要的。特别是
externalBlocks
在这种情况下可能会帮助你:

https://docs.typo3.org/m/typo3/reference-typoscript/main/en-us/Functions/Parsefunc.html#externalblocks

© www.soinside.com 2019 - 2024. All rights reserved.