I want to change content on home page when user is logged in and for now was working fine:
add_shortcode("change_home_page_content","shortcode");
function shortcode(){
if ( is_user_logged_in() ) {
echo '<html> ... </html>';
} else {
echo '<html> ... </html>';
}
}
but now, when user logged in every page is working (user is still logged in) except home page - user is automatically logged out.
I use w3 total cache and if I purge all cache from dashboard is working and if I clear all object cache is working, but don't now why I can't manualy delete all object cache from ftp.
Also if I delete cache from browser user is automatically logged in when I refresh page ...
I think problem was in cache plugin. First I was deactivate W3 total cache so I can delete object cache from ftp and then I try back activate W3 total cache. Because problem stays I switched to WP Fastest Cache and for now is working fine.