Support » Plugin: Custom Dashboard & Login Page - AGCA » Error 500 general-setting

  • Hello,

    I moved host yesterday and I update WP to 4.7. And Multisite actived

    All work when I login as admin in dashboard, but for all other, I have a 500 error when they check site.

    Log:
    PHP message: PHP Fatal error: require_once(): Failed opening required '/var/www/html//wp-admin/includes/plugin.php#general-settings' (include_path='.:/usr/share/php') in /var/www/html/wp-content/plugins/ag-custom-admin/plugin.php on line 442" while reading response header from upstream, client: 10.0.2.253, server: ...., request: "GET / HTTP/1.1", upstream: "fastcgi://unix:/run/php/php7.0-fpm.sock:", host: "....."

        function WPSPluginIsLoginPage(){
    
                    $WPSPluginName = 'wps-hide-login/wps-hide-login.php';
                    if(is_multisite()){
                            if ( ! function_exists( 'is_plugin_active_for_network' ) )
                            require_once( ABSPATH . '/wp-admin/includes/plugin.php#general-settings' );
    
                            if(!$this->isPluginActiveForNetwork($WPSPluginName)){
                                    return '';
                            }
                    }else{
                            if(!$this->isPluginActive($WPSPluginName)){
                                    return '';
                            }
                    }
    
            if ( $slug = get_option( 'whl_page' ) ) {
                return $slug;
            } else if ( ( is_multisite() && $this->isPluginActiveForNetwork($WPSPluginName) && ( $slug = get_site_option( 'whl_page', 'login' ) ) ) ) {
                return $slug;
            } else if ( $slug = 'login' ) {
                return $slug;
            }
            $requestURI = $_SERVER['REQUEST_URI'];
            return $this->startsWith('/'.$slug.'/', $requestURI);
        }
    

    Thanks,

Viewing 4 replies - 1 through 4 (of 4 total)
  • It could be something with your wp-config.php file. Please open it add check if ABSPATH i defined correctly, example:

    * That's all, stop editing! Happy blogging. */
    
    /** Absolute path to the WordPress directory. */
    if ( !defined('ABSPATH') )
    	define('ABSPATH', dirname(__FILE__) . '/');
    
    /** Sets up WordPress vars and included files. */
    require_once(ABSPATH . 'wp-settings.php');

    You could also check the permissions of the file, make sure it’s 755.

    Thread Starter fgbq

    (@fgbq)

    Hello,

    Thanks,

    I tried, I check my wp-config and it’s all right. An also 755.

    Same problem.

    Thanks,
    :'(

    Please try also replacing the line with the following (inside WPSPluginIsLoginPage function):

    require_once( trailingslashit(ABSPATH) . 'wp-admin/includes/plugin.php#general-settings' );

    • This reply was modified 6 years, 1 month ago by WAP Support.
    Thread Starter fgbq

    (@fgbq)

    Hello,

    Sorry for long time response, but error still:

    PHP message: PHP Fatal error: require_once(): Failed opening required '/var/www/html/wp-admin/includes/plugin.php#general-settings' (include_path='.:/usr/share/php') in /var/www/html/wp-content/plugins/ag-custom-admin/plugin.php on line 443" while reading response header from upstream, client: ...., server: ..., request: "GET / HTTP/1.1", upstream: "fastcgi://unix:/run/php/php7.0-fpm.sock:", host: "......"

    I see in upgrade cusmin, but not work for multi-site. So I have to work with AG Custom.

    Thanks

    • This reply was modified 6 years ago by fgbq.
    • This reply was modified 6 years ago by fgbq.
Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Error 500 general-setting’ is closed to new replies.