TYPO3 - 在自己的扩展中停用 cHash - 8LTS [英] TYPO3 - Deactivating cHash in own extension - 8LTS
本文介绍了TYPO3 - 在自己的扩展中停用 cHash - 8LTS的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在尝试在我的扩展程序中停用 cHash ...显示操作的链接如下所示:
I'm trying to deactivate cHash in my extension ... the link for the show action looks like this:
/?tx_abc_abc[record]=1&tx_abc_abc[action]=show&tx_abc_abc[controller]=Abc&cHash=10c78febea3ae5dsdf535fb36ca6d08
在 ext_localconf.php 中,我尝试像这样停用 cHash:
In ext_localconf.php I tried to deactivate cHash like this:
ext_localconf.php
ext_localconf.php
<?php
if (!defined('TYPO3_MODE')) {
die('Access denied.');
}
\TYPO3\CMS\Extbase\Utility\ExtensionUtility::configurePlugin(
'Vendor.' . $_EXTKEY,
'Abc',
array(
'Abc' => 'list,show',
),
// non-cacheable actions
array(
'Abc' => 'list,show',
)
);
$GLOBALS['TYPO3_CONF_VARS']['FE']['cacheHash']['excludedParameters'][] = 'tx_abc_abc[record],tx_abc_abc[action],tx_abc_abc[controller]';
但它不起作用.我错过了什么?
It's not working though. What am I missing?
推荐答案
在模板中构建链接时,您需要停用 cHash.如果您使用的是 ViewHelper
,那么您需要设置属性 noCacheHash="1"
.
You need to deactivate the cHash when building the links in your template. If you are using the ViewHelper <f:link.action>
, then you need to set the attribute noCacheHash="1"
.
这篇关于TYPO3 - 在自己的扩展中停用 cHash - 8LTS的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文