0

We have a site which sometimes delivers a wrong content for a specific URL.
The page has a plugin and by default should show the records listing (or the first record listing as the listing is grouped by initial letter). After clicking a link some records are viewable in detail on the same page.

Every now and then a cache problem occurs: Instead of the listing a detailed record is shown.

Although we use realurl, all problems occur also with the basic urls.
For overview I will only write the url-parameters, assume www.domain.tld/index.php? in front.

The page to call is id=61.
What I see is
cHash=3df3421afc42d3d5bfa1bc50603ea00d&id=61&tx_citkoegovservicelight_ansprechpartner%5Baction%5D=show&tx_citkoegovservicelight_ansprechpartner%5Bansprechpartner%5D=282.

In the HTML-source of the page I show the page calling parameters with the extension page_params. Here I see:
tx_citkoegovservicelight_ansprechpartner[action]=show&tx_citkoegovservicelight_ansprechpartner[ansprechpartner]=282&tx_citkoegovservicelight_ansprechpartner[letter]=kontakt&id=61

Two strange notes: there is no cHash parameter, there is an additional parameter tx_citkoegovservicelight_ansprechpartner[letter] which never should be used with detail view and never should have the value kontakt (only single characters were used for the listing of all records starting with that letter = no detail view)

Using these parameters does not show the detail-view but the the list view (for letter 'A').

I do not find a reason why this special URL should be called (no link) and I don't know why TYPO3 should cache a content which belongs to another URL.
And it is a problem with TYPO3 cache as all works correct if I clear the cache of this single page.

Bernd Wilke πφ
  • 10,390
  • 1
  • 19
  • 38
  • 1
    I know that issue `Instead of the listing a detailed record is shown` from a custom extbase extension. After months of desperate fiddling (and difficulties to reproduce, as it doesn't occur right away), I've switched to using a separate page for list & detail, which is a pity for the URL path and more work to set up in the BE – but since then, the error is (of course) gone. – Urs Jun 12 '17 at 11:14

1 Answers1

0

Please check my answer to another issue. The accepted answer is right in that case, but in your case it can really be caused by failed cHash calculation, because it is not related to RealURL.

Try to clear the cache and then right after that go to tx_citkoegovservicelight_ansprechpartner[action]=show&tx_citkoegovservicelight_ansprechpartner[ansprechpartner]=282&tx_citkoegovservicelight_ansprechpartner[letter]=kontakt&id=61.

And then simply open the page id=61. If you see the wrong cached result, then the reason is in a combination of following factors:

  • Plugin's action is cached
  • Cache fails are allowed in installation
  • cHash calculation failed

To prevent this you should enable pageNotFoundOnCHashError in Install Tool. Then the problematic link above will just trigger 404 and will not force TYPO3 to render the page.

To a question where the link is coming from. If the website is already live, it can be everything: from a crawler, which somehow builded the link itself to a user who tried to play with parameters.

Viktor Livakivskyi
  • 3,178
  • 1
  • 21
  • 33
  • `Plugin's action is cached` yes, `Cache fails are allowed in installation` no, `cHash calculation failed` seems so. – Bernd Wilke πφ Jun 13 '17 at 11:18
  • So, `pageNotFoundOnCHashError ` is enabled, but when you call `tx_citkoegovservicelight_ansprechpartner[action]=show&tx_citkoegovservicelight_ansprechpartner[ansprechpartner]=282&tx_citkoegovservicelight_ansprechpartner[letter]=kontakt&id=61` you see a plugin output instead of 404? – Viktor Livakivskyi Jun 13 '17 at 11:23
  • yes. after clearing the cache I see the record detail view. the problem might be that the additional paramter(letter) is a valid paramter, but it is not valid in detail view (only list view). and there still is no chash at all. – Bernd Wilke πφ Jun 14 '17 at 06:11
  • @BerndWilkeπφ if still relevant, just discovered similar issue in one of our client's websites. What helped - set `[FE][cHashRequiredParameters]` to `tx_citkoegovservicelight_ansprechpartner[ansprechpartner]`. This will force TYPO3 to check for cHash for all links, which have this parameter. And if no cHash present or it is wrong, a "not found" behavior will be triggered preventing page to be stored in TYPO3 cache. – Viktor Livakivskyi Jul 27 '17 at 11:01