[TYPO3-english] Cache issue with variables...

Roberto Presedo rpresedo.typo3 at gmail.com
Fri Feb 24 15:33:51 CET 2012


Ok, I added chash to all links, and cache issue is half-solved…
It works when real url is off, but not when it's on :( … I guess this is
real url config issue… I'll dig it..

Thanks again for your answers

2012/2/23 Roberto Presedo <rpresedo.typo3 at gmail.com>

> ok, thank you for the advices….
>
> I tried to add chashes to all links, but how to add chashes to links
> created by MENU object ?
>
> Thanks
>
> 2012/2/23 Bernd Wilke <t3ng at pi-phi.tk>
>
> > On 02/23/2012 04:18 AM, Roberto Presedo wrote:
> >
> >> Hello…
> >>
> >> I'm trying to use a "country" variable that will be used by TYPO3 in
> every
> >> links it will generate, as it does with the "L" variable for the
> language
> >> of a page.
> >>
> >> What I expect is the following : If I load a page like "
> >> www.mysite.com/?id=1&L=1&**country=de<
> http://www.mysite.com/?id=1&L=1&country=de>",
> >> I want all links generated in that
> >> page to use "L" and "country" variables.
> >>
> >> for example the following page
> >> *->www.mysite.com/?id=1&L=1&**country=de<
> http://www.mysite.com/?id=1&L=1&country=de>
> >> *will contain links like :
> >> www.mysite.com/?id=32&L=1&**country=de<
> http://www.mysite.com/?id=32&L=1&country=de>
> >> www.mysite.com/?id=33&L=1&**country=de&onemorevariable=xx<
> http://www.mysite.com/?id=33&L=1&country=de&onemorevariable=xx>
> >> ...
> >>
> >> To do so, I've set up the Ts config like this
> >>
> >> config.linkVars = L(0-5),country
> >>
> >> It works fine, as L and country are added to all links of my page.. but
> ..
> >>
> >> Let say I load the following url for the first time (cache previously
> >> cleared)
> >> *->  www.mysite.com/?id=1&L=1&**country=de<
> http://www.mysite.com/?id=1&L=1&country=de>
> >> *will generates links with L=1&country=de as expected…
> >>
> >> If I switch language
> >> *->  www.mysite.com/?id=1&L=2&**country=de<
> http://www.mysite.com/?id=1&L=2&country=de>
> >> *Links are generated as expected too (with L=2&country=de) … good
> >>
> >> But if I switch country instead of language,
> >> *->  www.mysite.com/?id=1&L=1&**country=ch<
> http://www.mysite.com/?id=1&L=1&country=ch>
> >> *then TYPO3 is going to check in the cache for the page requested (as
> >> usual), but will return the content of the first loaded country/language
> >> pair (www.mysite.com/?id=1&L=1&**country=de<
> http://www.mysite.com/?id=1&L=1&country=de>)
> >> instead of create a brand new
> >> content, as the page as never been generated before.. So, the page
> >> returned
> >> contains links with "L=1&country=de" instead of "L=1&country=ch" and I
> >> loose the country=de information.
> >>
> >> How can I tell the cache framework to look after the "L" variable AND
> the
> >> "country" one too…
> >>
> >
> > as georg wrote: the clean way is to use cHash and all url-parameters are
> > distinguished.
> >
> > the 'old' variant:
> > caching depends on:
> > 1. Typoscript-conditions
> > 2. fe_usergroups of logged in user
> > so if you want to cache different values of country you can build in
> > conditions on these values. but be aware that other variables which might
> > lead to other pagecontent (like 'onemorevariable=xx') are still ignored,
> > which can be ok if the value is evaluated just in an uncached extension.
> >
> > bernd
> > --
> > http://www.pi-phi.de/**cheatsheet.html<
> http://www.pi-phi.de/cheatsheet.html>
> >
> > ______________________________**_________________
> > TYPO3-english mailing list
> > TYPO3-english at lists.typo3.org
> > http://lists.typo3.org/cgi-**bin/mailman/listinfo/typo3-**english<
> http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-english>
> >
> _______________________________________________
> TYPO3-english mailing list
> TYPO3-english at lists.typo3.org
> http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-english
>


More information about the TYPO3-english mailing list