[TYPO3-dev] caching of pages with more than id and type params (with or without cHash)

Franz Holzinger franz at fholzinger.com
Mon May 1 12:51:42 CEST 2006


Hello Martins,
> 
> i made the link vars configurable with ts for the extension because i
> think the urls are more readable that way. so i have to get along with
> these values.
> 
> the other reason is that forms cannot use "tx_myext_pi1[feature]" names
> together with the "get" method. i want to use "get" for the searchform
> to make it transparent for the user.
> 
> i think i will use the custom cHash way. i hope i get along with these
> functions.
> 
> 
> tslib_pibase::pi_getPageLink
> t3lib_div::cHashParams
> tslib_fe::makeCacheHash
> 

How did you solve this that
in class.t3lib_content.php
function typoLink($linktxt, $conf)	{
....
} elseif ($conf['useCacheHash']) {	// cache hashing:
	$pA =
t3lib_div::cHashParams($addQueryParams.$GLOBALS['TSFE']->linkVars);	//
Added '.$this->linkVars' dec 2003: The need for adding the linkVars is
that they will be included in the link, but not the cHash. Thus the
linkVars will always be the problem that prevents the cHash from
working. I cannot see what negative implications in terms of
incompatibilities this could bring, but for now I hope there are none.
So here we go... (- kasper)
	$addQueryParams.= '&cHash='.t3lib_div::shortMD5(serialize($pA));
}

can be used?

Unfortunately I did not find any function which sets $conf['useCacheHash'].
So how shall the generated
$pA = t3lib_div::cHashParams($addQueryParams);
now come into
$this->cObj->getTypoLink(
and set with cHash ?
E.g. in tt_guest I have

$rc = '<li class="prev">'.$this->cObj->getTypoLink(
	$label,
	$TSFE->id,
	$pA,
	'').'</li>';


Greets,

Franz
















More information about the TYPO3-dev mailing list