You are here

function esi_theme_is_esied in ESI: Edge Side Includes 6.2

See if the block/pane has been esi-ed.

Parameters

$content: html that gets passed to the theme function.

2 calls to esi_theme_is_esied()
esi_panels_pane_content_alter in ./esi.module
Implementation of hook_pane_content_alter().
esi_theme_callback_logic in ./esi.theme.inc

File

./esi.module, line 117
Adds support for ESI (Edge-Side-Include) integration, allowing blocks to be\ delivered by ESI, with support for per-block cache times.

Code

function esi_theme_is_esied($content) {

  // Content starts with "<esi:include src".
  // OR content ends with "class="esi-ajax"></div>".
  // OR content starts with "<!--# include virtual=".
  if (strpos($content, '<esi:include src=') === 0 || strpos($content, 'class="esi-ajax"></div>') === strlen($content) - 23 || strpos($content, '<!--# include virtual=') === 0) {
    return TRUE;
  }
  return FALSE;
}