This is an old revision of the document!


Please note that this will requires v3.0 rc 10 and later.

add following code

apply_filters( 'litespeed_esi_url', 'my_esi_block', 'Custom ESI block' );

to where you want to insert the block, for example :

some_code_here
<div>
apply_filters( 'litespeed_esi_url', 'my_esi_block', 'Custom ESI block' );
</div>
some_code_here

and then add following code into your theme's functions.php:

add_action( 'litespeed_esi_load-my_esi_block', 'my_esi_block_esi_load' );

function my_esi_block_esi()
{
echo "Hello world";
}

where my_esi_block is the block name , for your convenience , Custom ESI block is short comment

  • Admin
  • Last modified: 2020/04/02 20:58
  • by qtwrk