ESI block not showing up




Wordpress LScache Plugin: ESI block not showing up

Last Updated on: Wed, 15 Apr 2026 00:00:02
Im developing a widget on which will show the users address based on the postcode he enters. But with the cache active, the address always ends up being the first postcode entered, if you change the postcode, the address changes as a result, but when you change the page it still shows the previous address. The solution would probably be using the ESI Block Url, I followed the example https://docs.litespeedtech.com/lscache/lscwp/api/#generate-esi-block-url but even with the example for me it doesnt load anything, the block it is empty. In the source code it even shows the block, with src, if I access the src I can see the content that it should show there, but on the page it doesnt. The code used to show the block is this: echo apply_filters( litespeed_esi_url, location_block, Localiza??o de entrega ) The code in function.php is this: add_action( litespeed_esi_load-location_block, location_block_esi_load ) function location_block_esi_load() #do_action( litespeed_control_set_ttl, 3 ) do_action( litespeed_control_set_nocache ) echo Ser? que entrega? The page I need help with: https://notmagic.uili.com.br/ Hi, are you using OpenLiteSpeed ? Well, I found out that it only works with LiteSpeed Server Enterprise right after I opened this topic. So I even managed to get it working after moving the installation to a LiteSpeed Server but the site ended up being very slow with the same settings used in OpenLiteSpeed, perhaps due to lack of knowledge and familiarity with CyberPanel. So I ended up changing my plugin to work with Cookies instead of ESI and stick with OpenLiteSpeed.



LiteCache Rush: Speed comes from using less, not from doing it faster



Reference