[TYPO3-dev] Caching extension output without the cHash parameter

Popy popy.dev at gmail.com
Mon Aug 27 11:17:10 CEST 2007


So ugly...

2007/8/27, John de Stigter <John.de.Stigter at bedrijvenweb.nl>:
>
> Hi there,
>
> I am working on an extension with GET vars like tt_news that I want to
> be cached by TYPO3. I've read the article about the cHash parameter and
> this all works great, but I don't like the cHash value in my url's.
>
> To make this possible I have added some code to the function
> "makeCacheHash()" in the class "tslib_fe". What I do is I check if any
> $_GET variables are set that belong to my extension. If so, than I unset
> the $GET variable that is passed over and fill it up again with only the
> page id and the variables that belong to my extension. After this I
> calculate the cHash of my rebuilt $GET and set $this->cHash to that
> value.
>
> This will enable indexing of the extension output and also cache the
> page without having that ugly :D cHash parameter in my url's.
>
> I tried to add this solution with the availble "tslib_fe-PostProc" hook,
> but since I am also using RealURL, my GET variables are not set at this
> point yet.
>
> As far as I have tested this the above solution does not open up a
> threat as mentioned in the article about cHash, but if anyone thinks it
> could, please post it or mail me.
>
> I am also wondering if this functionality could be included in the core
> of TYPO3. I am aware it could slow down the page rendering process, but
> in case you have a heavy extension and you want to exclude the cHash
> paramter from your url's it improves your website.
>
> You can find the manipulated function in the attachement.
>
> Article on cHash:
> http://typo3.org/development/articles/the-mysteries-of-chash/page/1/
>
> <<function.txt>>
> Cheerios,
> John
>
>
> _______________________________________________
> TYPO3-dev mailing list
> TYPO3-dev at lists.netfielders.de
> http://lists.netfielders.de/cgi-bin/mailman/listinfo/typo3-dev
>
>


-- 
Popy

Vulnerant omnes, ultima necat.

http://popy.sytes.net




More information about the TYPO3-dev mailing list