move make_session_dir_recursively function to compatible.php