New Community Forums are coming. Watch this space for news.
Subscribe: RSS
  • Connecting to database server:
    Could not connect to the database server. Check the connection properties and try again.

    [2016-01-31 09:14:02] (ERROR in xPDOConnection::connect @ C:\wamp\www\modx\core\xpdo\xpdo.class.php : 3058) SQLSTATE[HY000] [1045] Access denied for user 'demo'@'localhost' (using password: YES)

    [2016-01-31 09:14:02] (ERROR in xPDOConnection::connect @ C:\wamp\www\modx\core\xpdo\xpdo.class.php : 3058) SQLSTATE[HY000] [1045] Access denied for user 'demo'@'localhost' (using password: YES)

    I am using wamp server instead of filezilla, I get this error when i try to enter database name while installation.

    Thank you in advance smiley
    • There is something wrong with the database details (database name, username, password) you are using.
        Studying MODX in the desert - http://sottwell.com
        Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
        Join the Slack Community - http://modx.org
      • should i create a new database manually??
        • When the error says "access denied for user@database" and "using password = YES" that means that the database does exist, but the user and/or the password are not accepted.
            Studying MODX in the desert - http://sottwell.com
            Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
            Join the Slack Community - http://modx.org
          • Just did a fresh/advanced install of ModX Revolution this morning and was having this problem. Even ran a pdo testing .php file and got the same error repeatedly. Thought I was going crazy for a minute. Checking file permissions, php extensions, etc and all the obvious errors as suggested on the install guide and elsewhere. No luck.

            I finally got it to install. The problem? It would appear that the installer fails to escape the password when a ' is present. Since I used a password generator and the install script/guides/etc make no mention of this pitfall, I thought I'd share to prevent heartache in the future.
            • Hi,
              I am very new to MODX. I have installed MODX Rev. without any problem in localhost but when I decide to install MODX on my server the installation process completed successfully without any errors and warnings and at the end of installation, MODX can't delete the 'setup' folder and I have not received any error message for deleting of setup folder too.

              Also when I check my database in phpmyadmin the database is empty. While I browse my domain I get the error 500 and site is temporarily unavailable.

              The folders permission is 755 (in filezilla it is 2755) and the files permission is 644.
              • What character set and collation did you use for your installation's database?

                There should be a file in the core/cache/logs/ directory for the installation log, install.config<date-time>.log
                  Studying MODX in the desert - http://sottwell.com
                  Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
                  Join the Slack Community - http://modx.org
                • Hello,

                  I am totally new to MODX, I am running XAMPP v3.2.2 and PHP v7.0.2, I have downloaded MODX Revolution tried to install on my localhost using the following command: c:/MODX_DEV1/setup/index.php which results in the following error being displayed:

                  $argv) { $p = explode('=',ltrim($argv,'--')); if (isset($p[1])) { $_REQUEST[$p[0]] = $p[1]; } } if (!empty($_REQUEST['core_path']) && is_dir($_REQUEST['core_path'])) { define('MODX_CORE_PATH',$_REQUEST['core_path']); } if (!empty($_REQUEST['config_key'])) { define('MODX_CONFIG_KEY',$_REQUEST['config_key']); } } /* check for compatible PHP version */ define('MODX_SETUP_PHP_VERSION', phpversion()); $php_ver_comp = version_compare(MODX_SETUP_PHP_VERSION, '5.1.1'); if ($php_ver_comp < 0) { die('
                  FATAL ERROR: MODX Setup cannot continue.

                  Wrong PHP version! You\'re using PHP version '.MODX_SETUP_PHP_VERSION.', and MODX requires version 5.1.1 or higher.
                  '); } /* make sure json extension is available */ if (!function_exists('json_encode')) { die('
                  FATAL ERROR: MODX Setup cannot continue.

                  MODX requires the PHP JSON extension! You\'re PHP configuration at version '.MODX_SETUP_PHP_VERSION.' does not appear to have this extension enabled. This should be a standard extension on PHP 5.2+; it is available as a PECL extension in 5.1.
                  '); } /* make sure date.timezone is set for PHP 5.3.0+ users */ if (version_compare(MODX_SETUP_PHP_VERSION,'5.3.0') >= 0) { $phptz = @ini_get('date.timezone'); if (empty($phptz)) { date_default_timezone_set('UTC'); } if (!date_default_timezone_get()) { die('
                  FATAL ERROR: MODX Setup cannot continue.

                  To use PHP 5.3.0+, you must set the date.timezone setting in your php.ini (or have at least UTC in the list of supported timezones). Please do set it to a proper timezone before proceeding. A list can be found here.
                  '); } } if (!$isCommandLine) { $https = isset($_SERVER['HTTPS']) ? $_SERVER['HTTPS'] : false; $installBaseUrl= (!$https || strtolower($https) != 'on') ? 'http://' : 'https://'; $installBaseUrl .= $_SERVER['HTTP_HOST']; if (isset($_SERVER['SERVER_PORT']) && (string)$_SERVER['SERVER_PORT'] != '' && $_SERVER['SERVER_PORT'] != 80) $installBaseUrl= str_replace(':' . $_SERVER['SERVER_PORT'], '', $installBaseUrl); $installBaseUrl .= ($_SERVER['SERVER_PORT'] == 80 || ($https !== false || strtolower($https) == 'on')) ? '' : ':' . $_SERVER['SERVER_PORT']; $installBaseUrl .= $_SERVER['SCRIPT_NAME']; define('MODX_SETUP_URL', $installBaseUrl); } else { define('MODX_SETUP_URL','/'); } /* session loop-back tester */ if (!$isCommandLine && (!isset($_GET['s']) || $_GET['s'] != 'set') && !isset($_SESSION['session_test'])) { $_SESSION['session_test']= 1; echo " [ed. note: barrington last edited this post 2 years, 7 months ago.]
                  • Put a test.php file in the c:/MODX_DEV1/ directory with this code:


                    <?php
                    phpinfo();
                    


                    Then point your browser at c:/MODX_DEV1/test.php

                    If it works, see what version of PHP it reports, what it says about the JSON extension. If it doesn't work at all, something is wrong with your XAMPP configuration.

                    BTW, usually the web root for XAMPP is the htdocs directory, typically C:/xampp/htdocs. Are you sure that c:/MODX_DEV1/ is the web root for XAMPP?

                    Ultimately, you may also need to set the date/timezone setting in XAMPP's php.ini file, but that issue may go away when you get PHP working properly.

                      Did I help you? Buy me a beer
                      Get my Book: MODX:The Official Guide
                      MODX info for everyone: http://bobsguides.com/modx.html
                      My MODX Extras
                      Bob's Guides is now hosted at A2 MODX Hosting