Title: &#8220;Late Initialization&#8221; possibility
Last modified: June 23, 2022

---

# “Late Initialization” possibility

 *  Resolved [travisparkerhall](https://wordpress.org/support/users/travisparkerhall/)
 * (@travisparkerhall)
 * [3 years, 9 months ago](https://wordpress.org/support/topic/late-initialization-possibility/)
 * Hello,
    We have a special plugin. It is for find the visitor source and arrange
   data for their origin. It is already integrated with WP Super Cache and W3TC 
   as they were serving good hooks but I couldn’t find Litespeed cache options for
   that. I saw some message from Litespeed support talking about “litespeed_buffer_before”
   but couldn’t make it work.
 * My code is basically something like below.
    Thank you so much.
 * ##########
 *     ```
       if($settings['cache_plugin_use']=='super_cache'){
       		$GLOBALS['wp_super_cache_late_init'] =1;
       	}elseif($settings['cache_plugin_use']=='w3tc'){
       		if(function_exists('w3tc_config')){
       			$config = w3tc_config();
       			//echo '<pre>'; print_r($config); exit;
       			if($config->get_boolean('pgcache.late_init') == false || $config->get_string( 'pgcache.engine' ) != 'file'){
       				$config->set( 'pgcache.engine', 'file' );
       				$config->set( 'pgcache.late_init', true );
       				$config->save();
       			}
       		}
       	}
       ```
   
 * ##########

Viewing 1 replies (of 1 total)

 *  Plugin Support [qtwrk](https://wordpress.org/support/users/qtwrk/)
 * (@qtwrk)
 * [3 years, 9 months ago](https://wordpress.org/support/topic/late-initialization-possibility/#post-15766038)
 * Hi,
 * please forgive my bluntness, what kind of hook you are looking for to make this
   work ?
 * Best regards,

Viewing 1 replies (of 1 total)

The topic ‘“Late Initialization” possibility’ is closed to new replies.

 * ![](https://ps.w.org/litespeed-cache/assets/icon-256x256.png?rev=2554181)
 * [LiteSpeed Cache](https://wordpress.org/plugins/litespeed-cache/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/litespeed-cache/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/litespeed-cache/)
 * [Active Topics](https://wordpress.org/support/plugin/litespeed-cache/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/litespeed-cache/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/litespeed-cache/reviews/)

## Tags

 * [cache](https://wordpress.org/support/topic-tag/cache/)
 * [init](https://wordpress.org/support/topic-tag/init/)
 * [initialization](https://wordpress.org/support/topic-tag/initialization/)
 * [late](https://wordpress.org/support/topic-tag/late/)

 * 1 reply
 * 2 participants
 * Last reply from: [qtwrk](https://wordpress.org/support/users/qtwrk/)
 * Last activity: [3 years, 9 months ago](https://wordpress.org/support/topic/late-initialization-possibility/#post-15766038)
 * Status: resolved