We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 42126
    • 5 Posts
    Hi,
    After having my site running fine for many months, I have just gone to log in to realise that the backend is broken. Getting an Error 500 message.

    I downloaded test_config.php and it is giving me this message.

    Warning: Invalid argument supplied for foreach() in /home/sderm/public_html/test_config.php on line 273
    Error
    The following errors were detected:
    Error reading workspaces table.

    I would like to re-run the setup of my current version of modx to try and get this fixed, but I dont know the version it currently using (as I cant see the backend)
    Is there any way to find this out not using the manager?

    Thanks in advance!

      • 30585
      • 833 Posts
      To find out what version of MODX you're running, open your MODX database and look for the settings_version in the modx_system_settings table.
        A MODx Fanatic
        • 28042 ☆ A M B ☆
        • 24,524 Posts
        You should just be able to check and repair that table.
          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
          • 42126
          • 5 Posts
          OK.. I couldnt find that settings_version in the table you mentioned, but I found the link to the help file for revo 2.2.. so I guess that is what I have.. Thanks.

          RE: Sotwell, Can you point me in the direction of "how to repair that table"? Thanks!




            • 28042 ☆ A M B ☆
            • 24,524 Posts
            If you have access to phpMyAdmin, you can use that to check and repair tables. Otherwise, it depends on what kind of database access you have.
              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
              • 42126
              • 5 Posts
              OK, tried repairing tables. Didnt help.

              Upgraded to the latest version of Modx, and ran setup, but it couldnt complete, and now I have Error 500 messages on both the front and back end.

              I had the site on a dev server that was working, so I upgraded that first, and it all went smoothly, so I know I did the upgrade correctly.

              This is what I have in the error log...

              [2013-11-13 12:27:28] (ERROR in xPDOConnection::connect @ /home/mydomainuser/public_html/core/xpdo/xpdo.class.php : 3051) SQLSTATE[HY000] [1045] Access denied for user 'solarde1_lazzaEb'@'localhost' (using password: YES)
              [2013-11-13 12:27:28] (ERROR in xPDOConnection::connect @ /home/mydomainuser/public_html/core/xpdo/xpdo.class.php : 3051) SQLSTATE[HY000] [1045] Access denied for user 'solarde1_lazzaEb'@'localhost' (using password: YES)
              [2013-11-13 12:27:28] (ERROR @ /index.php) Error preparing statement for query: SELECT `modSystemSetting`.`key` AS `modSystemSetting_key`, `modSystemSetting`.`value` AS `modSystemSetting_value`, `modSystemSetting`.`xtype` AS `modSystemSetting_xtype`, `modSystemSetting`.`namespace` AS `modSystemSetting_namespace`, `modSystemSetting`.`area` AS `modSystemSetting_area`, `modSystemSetting`.`editedon` AS `modSystemSetting_editedon` FROM `modx_system_settings` AS `modSystemSetting` -
              [2013-11-13 12:27:28] (ERROR in xPDOConnection::connect @ /home/mydomainuser/public_html/core/xpdo/xpdo.class.php : 3051) SQLSTATE[HY000] [1045] Access denied for user 'solarde1_lazzaEb'@'localhost' (using password: YES)
              [2013-11-13 12:27:28] (ERROR in xPDOConnection::connect @ /home/mydomainuser/public_html/core/xpdo/xpdo.class.php : 3051) SQLSTATE[HY000] [1045] Access denied for user 'solarde1_lazzaEb'@'localhost' (using password: YES)
              [2013-11-13 12:27:28] (ERROR @ /index.php) Error preparing statement for query: SELECT `modSystemSetting`.`key` AS `modSystemSetting_key`, `modSystemSetting`.`value` AS `modSystemSetting_value`, `modSystemSetting`.`xtype` AS `modSystemSetting_xtype`, `modSystemSetting`.`namespace` AS `modSystemSetting_namespace`, `modSystemSetting`.`area` AS `modSystemSetting_area`, `modSystemSetting`.`editedon` AS `modSystemSetting_editedon` FROM `modx_system_settings` AS `modSystemSetting` -
              [2013-11-13 12:27:28] (FATAL) Could not load core MODX configuration!

              Can anybody shed some light on what I should do next?
                • 28042 ☆ A M B ☆
                • 24,524 Posts
                Looks like something wrong with the database connection. Check your config.inc.php file and make sure it's using the correct database information.
                  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
                  • 42126
                  • 5 Posts
                  OK, I got somewhere. It seems the name of the hosting account had changed out of the blue.. I updated it up in the ocnfig.inc.php file and was able to complete the installation/upgrade.

                  Front end is now working, but on login to manager I am greeted with this message!

                  Fatal error: Uncaught exception 'SmartyException' with message 'Unable to load template file 'header.tpl''

                  and my error log is telling me this..
                  [2013-11-13 15:58:57] (ERROR @ /~domainname/manager/index.php) Could not find action file at: /home5/domainname/public_html/manager/controllers/default/security/login

                  Thanks for all your help so far! I think Im at the end of my tether though!
                    • 42126
                    • 5 Posts
                    OK, just to conclude, the server URL had changed in config file. Once I got all the paths fixed up, it allowed me to upgrade, and is now working again! (for the most part)

                    Thankyou for all your help! I think I learnt a lot along the way!

                    Now the only issue Im having is the manager login. If I put in my details, the page just refreshes.

                    If I do the password recovery, and use the link that is emailed, I can log in no problems.

                    Anyone Ever seen anything like that before?