| Server IP : 104.26.5.103 / Your IP : 216.73.216.4 Web Server : nginx/1.27.1 System : Linux in-5 5.15.0-143-generic #153-Ubuntu SMP Fri Jun 13 19:10:45 UTC 2025 x86_64 User : arabianexpress ( 1872) PHP Version : 8.0.30 Disable Function : exec,passthru,shell_exec,system,proc_open,popen,parse_ini_file,show_source MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /storage/v9321/rimskannur/public_html/wp-content/themes/skole/vamtam/customizer/ |
Upload File : |
<?php
function vamtam_recompile_css() {
global $vamtam_theme;
vamtam_customizer_compiler( $vamtam_theme );
}
// "clear cache" implementation
function vamtam_actions() {
if ( isset( $_GET['vamtam_action'] ) ) {
if ( 'clear_cache' === $_GET['vamtam_action'] ) {
vamtam_recompile_css();
wp_redirect( admin_url() );
}
}
}
add_action( 'admin_init', 'vamtam_actions' );
function vamtam_customizer_compiler( $options ) {
if ( is_network_admin() ) {
if ( class_exists( 'FLBuilderAdminSettings' ) ) {
FLBuilderAdminSettings::clear_cache_for_all_sites();
}
} else {
if ( class_exists( 'FLBuilderModel' ) ) {
// Clear builder cache.
FLBuilderModel::delete_asset_cache_for_all_posts();
}
// Clear theme cache.
if ( class_exists( 'FLCustomizer' ) && method_exists( 'FLCustomizer', 'clear_all_css_cache' ) ) {
FLCustomizer::clear_all_css_cache();
}
}
update_option( 'vamtam-css-cache-timestamp', time() );
}
add_action( 'vamtam_customizer/' . $opt_name . '/compiler', 'vamtam_customizer_compiler', 10, 1 );