admin_header( __( 'General Settings', 'wordpress-seo' ), true, 'yoast_wpseo_options', 'wpseo' ); echo $wpseo_admin_pages->hidden( 'ignore_blog_public_warning' ); echo $wpseo_admin_pages->hidden( 'ignore_tour' ); echo $wpseo_admin_pages->hidden( 'ignore_page_comments' ); echo $wpseo_admin_pages->hidden( 'ignore_permalink' ); echo $wpseo_admin_pages->hidden( 'ms_defaults_set' ); echo $wpseo_admin_pages->hidden( 'version' ); echo $wpseo_admin_pages->hidden( 'tracking_popup' ); if ( isset( $options['blocking_files'] ) && is_array( $options['blocking_files'] ) && count( $options['blocking_files'] ) > 0 ) { $options['blocking_files'] = array_unique( $options['blocking_files'] ); echo '

' . '' . __( 'Fix it.', 'wordpress-seo' ) . '' . __( 'The following file(s) is/are blocking your XML sitemaps from working properly:', 'wordpress-seo' ) . '
'; foreach ( $options['blocking_files'] as $file ) { echo esc_html( $file ) . '
'; } echo __( 'Either delete them (this can be done with the "Fix it" button) or disable WP SEO XML sitemaps.', 'wordpress-seo' ); echo '

'; } if ( isset( $_GET['fixmetadesc'] ) && check_admin_referer( 'wpseo-fix-metadesc', 'nonce' ) && isset( $options['theme_check'] ) && isset( $options['theme_check']['description_found'] ) && $options['theme_check']['description_found'] ) { $fcontent = file_get_contents( TEMPLATEPATH . '/header.php' ); $msg = ''; if ( !file_exists( TEMPLATEPATH . '/header.php.wpseobak' ) ) { $backupfile = fopen( TEMPLATEPATH . '/header.php.wpseobak', 'w+' ); if ( $backupfile ) { fwrite( $backupfile, $fcontent ); fclose( $backupfile ); $msg = __( 'Backed up the original file header.php to header.php.wpseobak, ', 'wordpress-seo' ); $count = 0; $fcontent = str_replace( $options['theme_check']['description_found'], '', $fcontent, $count ); if ( $count > 0 ) { $header_file = fopen( TEMPLATEPATH . '/header.php', 'w+' ); if ( $header_file ) { fwrite( $header_file, $fcontent ); fclose( $header_file ); $msg .= __( 'removed hardcoded meta description.' ); } } unset( $options['theme_check']['description_found'] ); update_option( 'wpseo', $options ); } } } if ( !isset( $options['theme_check']['description'] ) ) { if ( file_exists( TEMPLATEPATH . '/header.php' ) ) { $header_file = file_get_contents( TEMPLATEPATH . '/header.php' ); $issue = preg_match_all( '#<\s*meta\s*(name|content)\s*=\s*("|\')(.*)("|\')\s*(name|content)\s*=\s*("|\')(.*)("|\')(\s+)?/?>#i', $header_file, $matches, PREG_SET_ORDER ); if ( !$issue ) { $options['theme_check']['description'] = true; } else { foreach ( $matches as $meta ) { if ( ( strtolower( $meta[1] ) == 'name' && strtolower( $meta[3] ) == 'description' ) || ( strtolower( $meta[5] ) == 'name' && strtolower( $meta[7] ) == 'description' ) ) { $options['theme_check']['description_found'] = $meta[0]; } } } update_option( 'wpseo', $options ); } if ( isset( $options['theme_check'] ) && isset( $options['theme_check']['description_found'] ) && $options['theme_check']['description_found'] ) { echo '

' . '' . __( 'Fix it.', 'wordpress-seo' ) . '' . __( 'Your theme contains a meta description, which blocks WordPress SEO from working properly, please delete the following line, or press fix it:', 'wordpress-seo' ) . '
'; echo '' . htmlentities( $options['theme_check']['description_found'] ) . ''; echo '

'; } } if ( strpos( get_option( 'permalink_structure' ), '%postname%' ) === false && !isset( $options['ignore_permalink'] ) ) echo ''; if ( get_option( 'page_comments' ) && !isset( $options['ignore_page_comments'] ) ) echo '

' . '' . __( 'Fix it.', 'wordpress-seo' ) . '' . '' . __( 'Ignore.', 'wordpress-seo' ) . '' . __( 'Paging comments is enabled, this is not needed in 999 out of 1000 cases, so the suggestion is to disable it, to do that, simply uncheck the box before "Break comments into pages..."', 'wordpress-seo' ) . '

'; echo '

' . __( 'General', 'wordpress-seo' ) . '

'; if ( isset( $options['ignore_tour'] ) && $options['ignore_tour'] ) { echo '' . __( 'Start Tour', 'wordpress-seo' ) . ''; echo '

' . __( 'Take this tour to quickly learn about the use of this plugin.', 'wordpress-seo' ) . '

'; } echo '' . __( 'Reset Default Settings', 'wordpress-seo' ) . ''; echo '

' . __( 'If you want to restore a site to the default WordPress SEO settings, press this button.', 'wordpress-seo' ) . '

'; echo '

' . __( 'Tracking', 'wordpress-seo' ) . '

'; echo $wpseo_admin_pages->checkbox( 'yoast_tracking', __( 'Allow tracking of this WordPress installs anonymous data.', 'wordpress-seo' ) ); echo '

' . __( "To maintain a plugin as big as WordPress SEO, we need to know what we're dealing: what kinds of other plugins our users are using, what themes, etc. Please allow us to track that data from your install. It will not track any user details, so your security and privacy are safe with us.", 'wordpress-seo' ) . '

'; echo '

' . __( 'Security', 'wordpress-seo' ) . '

'; echo $wpseo_admin_pages->checkbox( 'disableadvanced_meta', __( 'Disable the Advanced part of the WordPress SEO meta box', 'wordpress-seo' ) ); echo '

' . __( 'Unchecking this box allows authors and editors to redirect posts, noindex them and do other things you might not want if you don\'t trust your authors.', 'wordpress-seo' ) . '

'; echo '

' . __( 'Webmaster Tools', 'wordpress-seo' ) . '

'; echo '

' . __( 'You can use the boxes below to verify with the different Webmaster Tools, if your site is already verified, you can just forget about these. Enter the verify meta values for:', 'wordpress-seo' ) . '

'; echo $wpseo_admin_pages->textinput( 'googleverify', '' . __( 'Google Webmaster Tools', 'wordpress-seo' ) . '' ); echo $wpseo_admin_pages->textinput( 'msverify', '' . __( 'Bing Webmaster Tools', 'wordpress-seo' ) . '' ); echo $wpseo_admin_pages->textinput( 'alexaverify', '' . __( 'Alexa Verification ID', 'wordpress-seo' ) . '' ); do_action( 'wpseo_dashboard' ); $wpseo_admin_pages->admin_footer();