[TYPO3-english] typolink.addQueryString.exclude does not work ?

Gregory Loichot gloichot at cross-systems.com
Thu May 27 16:26:41 CEST 2010


FYI, in an extension, I did :

// Override linkVars while creating this typolink
$tmp = $GLOBALS["TSFE"]->linkVars;
$GLOBALS["TSFE"]->linkVars = "";

// Create typolink
$link = $this->cObj->typolink('', $linkConf);

// Restore linkVars
$GLOBALS["TSFE"]->linkVars = $tmp;

Maybe not "elegent" but I works.

Le 26.05.2010 15:09, Gregory Loichot a écrit :
> Hi,
>
> I'm using TYPO3 4.3.3 and I try to display a canonical tag on my pages
> (but my question is more global than canonical tag), so I wrote a small
> typoscript that *should* work :
>
> lib.canonical = TEXT
> lib.canonical.wrap = <link rel="canonical" href="|" />
> lib.canonical.typolink {
> parameter.data = page:uid
> useCacheHash = 1
> addQueryString = 1
> addQueryString.method = GET
> addQueryString.exclude = no_cache,cHash,tx_ttnews,tx_contentcountry_pi1
> returnLast = url
> }
> page.headerData.202 < lib.canonical
>
> Suppose URL like this :
> index.php?id=61&tx_contentcountry_pi1[country]=45&tx_contentcountry_pi1[zone]=1&tx_ttnews[tt_news]=35125&cHash=9bc8b2df916&no_cache=1
>
>
> My typoscript displays :
> <link rel="canonical"
> href="index.php?id=61&tx_contentcountry_pi1[country]=45&tx_contentcountry_pi1[zone]=1"
> />
>
> Question : why are tx_contentcountry_pi1 arguments no removed ?
>
> Thanks a lot,
> Greg



More information about the TYPO3-english mailing list