Hello,
Paste this code in your kleo-child theme functions.php
COPY CODE
/***************************************************
:: MAINTENANCE MODE
***************************************************/
if (!function_exists('kleo_maintenance_mode')) {
function kleo_maintenance_mode() {
$logo_path = apply_filters('kleo_logo', sq_option_url('logo'));
$logo_img = '<img src="'. $logo_path .'" alt="maintenance" />';
if (sq_option('maintenance_mode', 0) == 1) {
if ( !is_user_logged_in() ) {
wp_die(
$logo_img
. '<div style="text-align:center">'
. sq_option('maintenance_msg', '')
. '</div>',
get_bloginfo( 'name' )
);
}
}
}
add_action('get_header', 'kleo_maintenance_mode');
}
Logged in users can bypass the maintenance mode.
Let me know if is ok.
Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution