×

Welcome to TagMyCode

Please login or create account to add a snippet.
0
0
 
0
Language: Text
Posted by: Илья Праслов
Added: Jul 20, 2022 2:12 PM
Modified: Jul 24, 2022 6:14 PM
Views: 18
Tags: no tags
  1. "SET_LAST_MODIFIED" => "Y",
  2.  
  3. //section
  4. $cp = $this->__component; // объект компонента
  5. if (is_object($cp))
  6.    $cp->SetResultCacheKeys(array('ITEMS_TIMESTAMP_X'));
  7.  
  8. GLOBAL $lastModified;
  9. if (!$lastModified)
  10.    $lastModified = MakeTimeStamp($arResult['ITEMS_TIMESTAMP_X']);
  11. else
  12.    $lastModified = max($lastModified, MakeTimeStamp($arResult['ITEMS_TIMESTAMP_X']));
  13.  
  14. //detail
  15. $cp = $this->__component; // объект компонента
  16. if (is_object($cp))
  17.    $cp->SetResultCacheKeys(array('TIMESTAMP_X'));
  18.  
  19. GLOBAL $lastModified;
  20. if (!$lastModified)
  21.    $lastModified = MakeTimeStamp($arResult['TIMESTAMP_X']);
  22. else
  23.    $lastModified = max($lastModified, MakeTimeStamp($arResult['TIMESTAMP_X']));