add_setting_tab( __( 'Log', 'apppresser' ), 'log' ); } /** * Add the log template.php to the tab * @since 1.3.0 * @param array $arg1 */ public function appp_log_file_info( $arg1 ) { $this->template = self::$tmpl_path . $this->template; echo ''; $this->display_log(); echo ''; } /** * Removes the save settings button when viewing the log tab * @since 1.3.0 */ public function appp_remove_settings_save_button() { ?> get_log_file_name() ) { return file_get_contents( $this->get_log_file_name(), false ); } return ''; } /** * Displays the template of the log file and admin settings under the log tab * @since 1.3.0 */ public function display_log() { $file_exists = file_exists( AppPresser_Logger::$log_filepath ); $file_writeable = is_writeable( AppPresser_Logger::$log_filepath ); include_once $this->template; } } AppPresser_Log_Admin::run();