protected function render_description($form) { require_once ITSEC_Core::get_core_dir() . '/lib/class-itsec-lib-config-file.php'; $config = ITSEC_Lib_Config_File::get_wp_config(); if (empty($config)) { _e('There is nothing that needs to be written to your <code>wp-config.php</code> file.', 'better-wp-security'); } else { echo '<p>' . __("The following rules need to be written to your <code>wp-config.php</code> file. Please make sure to keep the comments in place.") . '</p>'; echo '<div class="itsec_rewrite_rules"><pre>' . esc_html($config) . '</pre></div>'; } }
/** * Echos content metabox contents. * * Echos the contents of the wp-config.php metabox * * @since 4.0.0 * * @return void */ public function config_metabox_contents() { require_once trailingslashit($GLOBALS['itsec_globals']['plugin_dir']) . 'core/lib/class-itsec-lib-config-file.php'; $config = ITSEC_Lib_Config_File::get_wp_config(); if (empty($config)) { _e('There are no rules to write.', 'better-wp-security'); } else { echo '<div class="itsec_rewrite_rules">' . highlight_string($config, true) . '</div>'; } }
/** * Echos content metabox contents. * * Echos the contents of the wp-config.php metabox * * @since 4.0.0 * * @return void */ public function config_metabox_contents() { require_once ITSEC_Core::get_core_dir() . '/lib/class-itsec-lib-config-file.php'; $config = ITSEC_Lib_Config_File::get_wp_config(); if (empty($config)) { _e('There are no rules to write.', 'better-wp-security'); } else { echo '<div class="itsec_rewrite_rules">' . highlight_string($config, true) . '</div>'; } }