label = __( 'robots.txt Viewer', 'health-check' );
$this->description = __( 'The robots.txt file tells search engines which folders are allowed to crawl and which not. WordPress generates a virtual files if there is no physical file. If there is a non-virtual file, the content is shown here.', 'health-check' );
parent::__construct();
}
public function tab_content() {
global $wp_rewrite;
if ( file_exists( ABSPATH . 'robots.txt' ) ) {
printf(
'
%s', esc_html( file_get_contents( ABSPATH . 'robots.txt' ) ) ); } else { printf( '
%s
', __( 'Your site is using the virtualrobots.txt file which is generated by WordPress.', 'health-check' )
);
}
?>