Dear community,
I’ve tried for several hours to fix this one:
First time install - I created database admin and dartabse as instructed. I get succes from:
Connection to host: passed - collations now available
but, when checking database I get:
Checking database: failed - could not create database
I know it exists, and I think the name is correct and the permissions are correct, but I can’t get past this screen.
Any help appreciated. I’ve attched some info about the servver version etc.
Many thanks.
-
☆ A M B ☆
- 24,524 Posts
Check the file install/connection.databasetest.php Line 19 should read:
if (!@ mysql_select_db(str_replace("`", "", $database_name), $conn)) {
Note the position of the $conn after the $database_name), and not inside the ). This appears to have been in a recent SVN version, but has been fixed as of revision 3825.
http://svn.modxcms.com/jira/browse/MODX-183
Thanks for the reeponse Susan. I have changed the code adn applied, but I still get the same error. Are there any more I should check?
Kind Regards,
hypnoman
-
☆ A M B ☆
- 24,524 Posts
No, that was the only problem I’ve seen, and it was the first installation failure I’ve ever had in three years of heavy MODx use.
You may not have permission to create new databases with the user (for example cPanel will not allow this). In this case you will need to create the database first (and possibly assign a user to the database) from the hosting control panel and then continue with the install.
Thanks for the advice. I’ve set up the db manually and it passes stage 1 of the verify connection. It’s just stage 2 where it tries to create the db (which I’ve already done)
Thanks
-
☆ A M B ☆
- 24,524 Posts
Where did you get your MODx archive from?
I downloaded it from the mods repository today. I’ll do the whole process again to make sure. I’ll even load it onto another virgin site, which is in the same ISP though. I’ll post the results here soon.
Does the Database name have an underscore or hyphen in it by any chance?
aha thta may be it. The database creates automatically prefixes so the database for modx for my site is shelleys_modx and I have no way of changing this. Is thisnthe issue?