We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 34004
    • 125 Posts
    I'm installing 2.2 (6th Dec nightly) to a site5 reseller account with a xxx.xxx.xxx.xxx/~xxxx/ address (staging before it goes to www.xxxxxx.com address). I can install successfully, however on first login to the manager I get the attached screenshot. Opening up firebug I get the following errors:

    GET http://46.20.118.12/~rubadub/manager/min/?f=/~rubadub/manager/templates/default/css/xtheme-modx.css,/~rubadub/manager/templates/default/css/index.css 400 (Bad Request)

    the error is regarding minify on several JS and CSS files, effectively halting all javascript loading, again please see attached screenshot.

    I did test this on a different site, and as soon as I went from the temporary xxx.xxx.xxx.xxx/~xxxx/ address to a legit www.xxxxx.com, minify worked. Am a bit puzzled as I'd really like to put 2.2 through its paces but need to have it on a staging server to test. Any clues?

    [ed. note: ficklelife last edited this post 14 years, 10 months ago.]
      • 22303 MODX Staff
      • 10,725 Posts
      What is the server reporting for SERVER_NAME and HTTP_HOST when using the temporary URL?
        • 34004
        • 125 Posts
        <?php
        print($_SERVER['SERVER_NAME']);
        print($_SERVER['HTTP_HOST']);
        ?>

        both are returning 46.20.118.12 which is the correct IP of the staging server.

          • 22303 MODX Staff
          • 10,725 Posts
          What is the base_url and site_url set to in the config file?
            • 34004
            • 125 Posts
            Here's everything below the password:



            if (!defined('MODX_CORE_PATH')) {
            $modx_core_path= '/home/rubadub/public_html/core/';
            define('MODX_CORE_PATH', $modx_core_path);
            }
            if (!defined('MODX_PROCESSORS_PATH')) {
            $modx_processors_path= '/home/rubadub/public_html/core/model/modx/processors/';
            define('MODX_PROCESSORS_PATH', $modx_processors_path);
            }
            if (!defined('MODX_CONNECTORS_PATH')) {
            $modx_connectors_path= '/home/rubadub/public_html/connectors/';
            $modx_connectors_url= '/~rubadub/connectors/';
            define('MODX_CONNECTORS_PATH', $modx_connectors_path);
            define('MODX_CONNECTORS_URL', $modx_connectors_url);
            }
            if (!defined('MODX_MANAGER_PATH')) {
            $modx_manager_path= '/home/rubadub/public_html/manager/';
            $modx_manager_url= '/~rubadub/manager/';
            define('MODX_MANAGER_PATH', $modx_manager_path);
            define('MODX_MANAGER_URL', $modx_manager_url);
            }
            if (!defined('MODX_BASE_PATH')) {
            $modx_base_path= '/home/rubadub/public_html/';
            $modx_base_url= '/~rubadub/';
            define('MODX_BASE_PATH', $modx_base_path);
            define('MODX_BASE_URL', $modx_base_url);
            }
            if(defined('PHP_SAPI') && (PHP_SAPI == "cli" || PHP_SAPI == "embed")) {
            $isSecureRequest = false;
            } else {
            $isSecureRequest = ((isset ($_SERVER['HTTPS']) && strtolower($_SERVER['HTTPS']) == 'on') || $_SERVER['SERVER_PORT'] == $https_port);
            }
            if (!defined('MODX_URL_SCHEME')) {
            $url_scheme= $isSecureRequest ? 'https://' : 'http://';
            define('MODX_URL_SCHEME', $url_scheme);
            }
            if (!defined('MODX_HTTP_HOST')) {
            if(defined('PHP_SAPI') && (PHP_SAPI == "cli" || PHP_SAPI == "embed")) {
            $http_host='46.20.118.12';
            define('MODX_HTTP_HOST', $http_host);
            } else {
            $http_host= $_SERVER['HTTP_HOST'];
            if ($_SERVER['SERVER_PORT'] != 80) {
            $http_host= str_replace(':' . $_SERVER['SERVER_PORT'], '', $http_host); // remove port from HTTP_HOST
            }
            $http_host .= ($_SERVER['SERVER_PORT'] == 80 || $isSecureRequest) ? '' : ':' . $_SERVER['SERVER_PORT'];
            define('MODX_HTTP_HOST', $http_host);
            }
            }
            if (!defined('MODX_SITE_URL')) {
            $site_url= $url_scheme . $http_host . MODX_BASE_URL;
            define('MODX_SITE_URL', $site_url);
            }
            if (!defined('MODX_ASSETS_PATH')) {
            $modx_assets_path= '/home/rubadub/public_html/assets/';
            $modx_assets_url= '/~rubadub/assets/';
            define('MODX_ASSETS_PATH', $modx_assets_path);
            define('MODX_ASSETS_URL', $modx_assets_url);
            }
            if (!defined('MODX_LOG_LEVEL_FATAL')) {
            define('MODX_LOG_LEVEL_FATAL', 0);
            define('MODX_LOG_LEVEL_ERROR', 1);
            define('MODX_LOG_LEVEL_WARN', 2);
            define('MODX_LOG_LEVEL_INFO', 3);
            define('MODX_LOG_LEVEL_DEBUG', 4);
            }
            if (!defined('MODX_CACHE_DISABLED')) {
            $modx_cache_disabled= false;
            define('MODX_CACHE_DISABLED', $modx_cache_disabled);
            }
              • 22303 MODX Staff
              • 10,725 Posts
              That all looks correct; can you file a bug for this so we can track the issue?
                • 34004
                • 125 Posts
                yep, filing now....
                  • 34004
                  • 125 Posts