Support » Plugin: NinjaFirewall (WP Edition) - Advanced Security Plugin and Firewall » nfwhook_load_textdomain error in php

  • Resolved FENOMICS

    (@fenomics)


    9.97.54.35:59793] mod_fcgid: stderr: PHP Warning: call_user_func_array() expects parameter 1 to be a valid callback, function ‘nfwhook_load_textdomain’ not found or invalid function name in /home/…./public_html/wp-includes/plugin.php on line 235

    creates a huge system log.. how can it be solved? thanks…

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author nintechnet

    (@nintechnet)

    This is a bug.
    Can you try to open the “/wp-content/ninjafirewall/ninjafirewall.php” script and to comment out lines 55, 60 and 68:

    54	global $wp_version;
    55  //	if ( version_compare( $wp_version, '4.6', '<' ) ) {
    56	        add_action( 'init', 'nfw_load_translation' );
    57	        function nfw_load_translation() {
    58	                load_plugin_textdomain('ninjafirewall', FALSE, dirname(plugin_basename(__FILE__)).'/languages/');
    59	        }
    60   //	} else {
    61	        function nfwhook_load_textdomain( $retval, $domain, $mofile ) {
    62	                if ( $domain == 'ninjafirewall' && strpos( $mofile, '/plugins/ninjafirewall-fr_FR.mo') !== false ) {
    63	                        load_textdomain('ninjafirewall', __DIR__ . '/languages/ninjafirewall-fr_FR.mo');
    64	                        return true;
    65	                }
    66	                return false;
    67	        }
    68 //	}
    69	add_filter('override_load_textdomain', 'nfwhook_load_textdomain', 10, 3);
    

    Simply add a double-slash ‘//’ at the beginning of each line as shown above.

    • This reply was modified 4 years, 4 months ago by nintechnet.

    Faced with the same problem. Thank you, your solution helped)

    Thread Starter FENOMICS

    (@fenomics)

    Will this bug be solved in the next version?

    Plugin Author nintechnet

    (@nintechnet)

    It will be fixed in the next release.
    This bug should only affect users running WordPress <4.6.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘nfwhook_load_textdomain error in php’ is closed to new replies.