升级到 9.5.17 后,我在报告中收到以下安全消息:
服务器对静态文件的响应:
www.mydomain.de/typo3temp/assets/43cd7f07.tmp/2500f854.html.wrong
unexpected content-type text/html
www.mydomain.de/typo3temp/assets/43cd7f07.tmp/2500f854.1.svg.wrong
unexpected content-type image/svg+xml
www.mydomain.de/typo3temp/assets/43cd7f07.tmp/2500f854.php.wrong
unexpected content PHP content
www.mydomain.de/typo3temp/assets/43cd7f07.tmp/2500f854.php.txt
unexpected content PHP content
Run Code Online (Sandbox Code Playgroud)
这是什么意思?
我检查了文件夹 /typo3temp/assets/ - 没有文件夹 43cd7f07.tmp
谢谢!
我想用自己的字段扩展 sys_file_reference 。所以我创建了该字段和 TCA。在后端,该字段可用,但我无法引用流体模板中的该字段。
ext_tables.php:
CREATE TABLE sys_file_reference (
nofollow int(11) DEFAULT '0' NOT NULL,
);
Run Code Online (Sandbox Code Playgroud)
配置/TCA/Overrides/sys_file_reference.php:
$tempColumns = array(
'nofollow' => array(
'exclude' => 1,
'l10n_mode' => 'mergeIfNotBlank',
'label' => 'Link als Nofollow?',
'config' => array(
'type' => 'check',
'default' => '0'
)
)
);
TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addTCAcolumns('sys_file_reference',$tempColumns,1);
TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addFieldsToPalette('sys_file_reference', 'imageoverlayPalette','--linebreak--,nofollow','after:description');
Run Code Online (Sandbox Code Playgroud)
到目前为止它在后端工作。
类/域/模型/MyFileReference.php
<?php
namespace LISARDO\Foerderland\Domain\Model;
use TYPO3\CMS\Extbase\Domain\Model\FileReference;
class MyFileReference extends FileReference {
/**
* nofollow
*
* @var integer
*/
protected $nofollow;
/**
* Returns the nofollow
*
* @return integer …Run Code Online (Sandbox Code Playgroud) 我想使用f:image或f:uri.imageviewhelper (TYPO3 8.7) 在 Fluid 中裁剪图像。从 TYPO3 7.2 开始,通常的方法不再有效:
这:
<f:image image="{file}" width="500c" height="500" />
Run Code Online (Sandbox Code Playgroud)
不起作用。
在流体指南中,我发现了从 TYPO3 7.2 开始我必须使用作物的提示。我在更改日志中找到了这一点: https://docs.typo3.org/typo3cms/extensions/core/7.6/Changelog/7.2/Feature-65584-AddImageCropping.html
所以这应该有效,但事实并非如此:
<f:image image="{file}" crop="0,0,500,500" />
Run Code Online (Sandbox Code Playgroud)
图像已渲染,但采用默认大小。
有任何想法吗?后来的版本有什么变化吗?
我需要这样的东西:
<f:link.typolink parameter="{link}">
Linktext
</f:link.typolink>
Run Code Online (Sandbox Code Playgroud)
但采用内联语法。这可能吗?谢谢!