I have a 2.2.2 development site I hadn't touched in a few months.
Recently the web host upgraded to PHP Version 5.3.22
Site came up with all the content, but the menus are gone.
I went to manager and got error 500
I copied over 2.2.6 files and ran setup - upgrade.
I get to where it actually does the setup and I get error 500.
I tried setup - new installation and nd I get error 500.
Sorry if it is something simple I overlooked, I am still learning.
I would think a new installation would go smoothly, but alas, it was not to be.
-
☆ A M B ☆
- 1,780 Posts
New installation will delete your database. Don't run setup as a new installation!!!
Chances are, when your host upgraded php, something was messed up with your php.ini file (doesn't exist, or is not configured for MODX perhaps?).
If you can downgrade to php 5.2, then try to access the site, and perhaps run the upgrade for MODX 2.2.6 while using php 5.2. Then upgrade php and make sure to configure the php.ini according to the setup information at the RTFM.
As always, take a backup of your database prior to running any upgrades.
The fact that it wanted to do a new install suggests that your core/config/config.inc.php file is missing. If you have the old one and can restore it, you can try an upgrade install. As Frogabog suggests, don't continue with the install if "New Install" is checked.
Put a line in htaccess to use php 5.2 and now it works.
Apparently ModX doesn't like php 5.3.
Never had a php.ini file. I guess I should RTFM. This is just a learning site.
Menus are still missing, but that's likely another issue.
Out of frustration I manually copied 2.2.6 files over the old 2.2.2 ones did a "new install". I didn't lose anything.
I was running php 5.3.? in the past, just not 5.3.22. Oh well, I'm switching hosting companies anyhow in a week or two, so it's all water under the bridge, or perhaps a bridge under water.
-
☆ A M B ☆
- 1,780 Posts
MODX likes PHP 3 just fine. I even had one install running 5.4 for a while, and it liked that fine too. What MODX doesn't like is an incorrectly configured php.ini file.
I guess it says "you may lose your database"... perhaps in some cases the database is preserved?
Normally though no, NEVER, EVER run a "new" install over the top of an existing installation. It's not something that will serve you well again, I'm afraid. You got lucky this time.
You have a php.ini file... you just may not be able to access it. It's the configuration file for php and it should change with the version (slight changes). Maybe your host has an interface linking to it, or maybe they don't allow you to touch it at all. But it's there for sure. Likely in the root. It's something you should take some time to learn about, because with an incorrectly configured php.ini MODX can function improperly.
The better hosts will give you access to your php.ini somehow. If you're switching hosts, consider that as a good sign. If you haven't decided which host to switch to, I recommend Skytoaster (see my sig). If you want to use MODX, they sure do make it simple. No worries about MODX config at all.