function fs_show_page($page, $is_file = true, $add_firestats_js = true, $hide_support_fs = false) { ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <title><?php fs_e('FireStats'); ?> </title> <?php fs_output_head(); ?> </head> <body> <?php if ($hide_support_fs) { global $fs_hide_support_button; $fs_hide_support_button = true; } require FS_ABS_PATH . "/php/header.php"; echo "\n"; if ($is_file) { echo "<!-- PAGE : {$page} -->\n"; require $page; } else { echo $page; } echo "\n"; require FS_ABS_PATH . "/php/footer.php"; ?> </body> </html> <?php }
function fs_admin_head() { $FS_PATH = fs_get_firestats_path(); if ($FS_PATH) { require_once $FS_PATH . '/php/init.php'; if (FS_WORDPRESS_PLUGIN_VER != FS_VERSION) { echo "Version mismatch between FireStats plugin (" . FS_WORDPRESS_PLUGIN_VER . ") and FireStats installation (" . FS_VERSION . ")"; return; } fs_authenticate_wp_user(); $name = $_SERVER["QUERY_STRING"]; if (fs_endsWith($name, 'firestats-wordpress.php')) { require_once $FS_PATH . '/php/html-utils.php'; fs_output_head(); } } }