[solved] if you remove Yoast SEO Comments and your site crashed? I'm fix it :)

Written by  Thursday, 16 November 2017 16:13

If you use Yoast for WP and press button 'Remove Yoast SEO Comments' - you can show this errors:

Fatal error: Uncaught Error: Call to undefined method RYSC::head_product_name() 
in /home/youraccount/sitename.com/www/wp-content/plugins/remove-yoast-seo-comments/remove-yoast-seo-comments.php(110) : eval()'d code:17 
Stack trace: #0 /home/youraccount/sitename.com/www/wp-content/plugins/remove-yoast-seo-comments/remove-yoast-seo-comments.php(110): eval() 
#1 /home/youraccount/sitename.com/www/wp-includes/class-wp-hook.php(286): RYSC->rewrite('') 
#2 /home/youraccount/sitename.com/www/wp-includes/class-wp-hook.php(310): WP_Hook->apply_filters(NULL, Array) 
#3 /home/youraccount/sitename.com/www/wp-includes/plugin.php(453): WP_Hook->do_action(Array) 
#4 /home/youraccount/sitename.com/www/wp-includes/general-template.php(2614): do_action('wp_head') 
#5 /home/youraccount/sitename.com/www/wp-content/themes/Newspaper/header.php(11): wp_head() 
#6 /home/youraccount/sitename.com/www/wp-includes/template.php(688): require_once('/home/youraccount/...') 
#7 /home/youraccount/sitename.com/www/wp-includes/template.php(647): load_template in /home/youraccount/sitename.com/www/wp-content/plugins/remove-yoast-seo-comments/remove-yoast-seo-comments.php(110) : eval()'d code on line 17

To fix it - Go to FTP -> open www/wp-content/plugins/ -> find folder remove-yoast-seo-comments and remove it or delete or rename (-remove-yoast-seo-comments)

Work done!

413 Read Last modified on Thursday, 16 November 2017

Related items

  • [solved] How to delete all version from cource code in css & js files with your theme

    For delete all version from css & js files in your Wordpress theme - I use function sdt_remove_ver_css_js with one argument. Add this code to your wp-content/themes/your-theme/function.php

    // Remove WP Version From Styles
    add_filter( 'style_loader_src', 'sdt_remove_ver_css_js', 9999 );
    // Remove WP Version From Scripts
    add_filter( 'script_loader_src', 'sdt_remove_ver_css_js', 9999 );
    
    // Function to remove version numbers
    function sdt_remove_ver_css_js( $src ) {
    	if ( strpos( $src, 'ver=' ) )
    		$src = remove_query_arg( 'ver', $src );
    	return $src;
    }

    Awesome!

  • [solved] Deprecated: Methods with the same name as their class will not be constructors ... www/plugins/content/jw_sigpro/jw_sigpro.php on line 19

    If you update your hosting to v7.1 & more - you can look same notification 'Deprecated: Methods with the same name as their class will not be constructors in a future version of PHP; plgContentJw_sigpro has a deprecated constructor in .../www/plugins/content/jw_sigpro/jw_sigpro.php on line 19'

    This code fix this problem you need Open plugins/content/jw_sigpro/jw_sigpro.php find this code in line 28:

    function plgContentJw_sigpro(&$subject, $params)
    	{
    		parent::__construct($subject, $params);
    
    		// Define the DS constant under Joomla! 3.0
    		if (!defined('DS'))
    		{
    			define('DS', DIRECTORY_SEPARATOR);
    		}
    	}

     And replase it to this code:

    public function __construct(&$subject, $params) {
    	parent::__construct($subject, $params);
    
    	// Define the DS constant under Joomla! 3.8.2+
    	if (!defined('DS')){
    		define('DS', DIRECTORY_SEPARATOR);
    	}
    }

    Awesome - it work done! :-)

    If you see same problem with jw_sig.php  - just download free new plugin from GitHub and install it: https://github.com/joomlaworks/simple-image-gallery