Attention

If your Photo Cart is suddenly getting a 500 error or only displaying a blank page then you or your hosting company has updated the PHP (programming language) to PHP 7 which Photo Cart is not compatible with (and will not be compatible with) mainly because of the removal of the my_sql functions which are replaced with my_sqli functions. 

You would need to have the PHP version downgraded to 5.6 in order for Photo Cart to work. If downgrading the PHP doesn't work then you may have to update Photo Cart to the last version of 7. Download Photo Cart 7 upgrade files. Upgrade instructions.

Photo Cart was retired in 2015. Check out Sytist.

Please log in or Create an account to post or reply to topics.
You will still receive notifications of replies to topics you are part of even if you do not subscribe to new topic emails.

Database Error Moving Photocart

G
4 posts
Sat Sep 14, 19 3:53 PM CST
We are changing hosting services.
I have followed the directions for backing up the database and creating a new one in the new hosting site. The database appears to be correct. I copied all the files over to the new server and modified the setup.php file. When I try to run Photocart, I get "Unable to locate the database: gharter1_harterphotocart" .
The name of the databas is correct. When I run a separate script outside photocart, it can find the database.
Any suggestions would be appreciated.
16,760 posts (admin)
Mon Sep 16, 19 5:28 AM CST
Maybe you have the hostname wrong, pc_db_host.

Might be localhost.
Tim Grissett, DIA - PicturesPro.com
My Email Address: info@picturespro.com
G
4 posts
Mon Sep 16, 19 7:00 AM CST
It is set to localhost.
I tried the pc_db_host and got a different error.
16,760 posts (admin)
Mon Sep 16, 19 10:19 AM CST
Basically your error, "Unable to locate the database: gharter1_harterphotocart, means it can not find a database by that name, gharter1_harterphotocart. Maybe you have a typo in it. You should double check that is the correct database name in your hosting control panel.
Tim Grissett, DIA - PicturesPro.com
My Email Address: info@picturespro.com
G
4 posts
Mon Sep 16, 19 9:25 PM CST
Thanks for the help.
I still have no idea why it can't find the database.
I double checked and everything is spelled correctly.

My settings are:
$setup['path']= dirname(__FILE__);
$setup['url'] = "http://".$_SERVER['HTTP_HOST']."/photocart";

// If you are going to use a payment option that requires an SSL enter your secure URL below
$setup['secure_url'] = "https://".$_SERVER['HTTP_HOST']."/photocart";


/* DATABASE SETTINGS */
$setup['pc_db_location'] = "localhost"; // hostname or location
$setup['pc_db'] = "gharter1_photocart"; // The name of the database
$setup['pc_db_user'] = "gharter1_gharter"; // username to the database
$setup['pc_db_pass'] = "photos"; // password to the database
Do you see anything wrong?
16,760 posts (admin)
Tue Sep 17, 19 6:02 AM CST
This database name:

$setup['pc_db'] = "gharter1_photocart"; // The name of the database

Is not the same name you posted before:

gharter1_harterphotocart,

Do you know which is right? And what is the EXACT error message now when you try?

And is that the right password? If not, have a password with no special characters like ^%$#@"'&
Tim Grissett, DIA - PicturesPro.com
My Email Address: info@picturespro.com
G
4 posts
Tue Sep 17, 19 7:01 AM CST
You are correct that the database name is different. When you mentioned to be sure the name was the same, I changed it in the database and the program to be sure they were the same. Still got the same error.

The password is correct.

Still get the same error: Unable to locate the database: gharter1_photocart. So even changing the name of the database, resetting the password, made no difference.
16,760 posts (admin)
Tue Sep 17, 19 7:34 AM CST
You will have to email me the link to your hosting control panel with username and password and the link of where you are trying to set this up.
Tim Grissett, DIA - PicturesPro.com
My Email Address: info@picturespro.com
8 total messages
Please log in or Create an account to post or reply to topics.
This post has been viewed 1,314 times
Category: Error
 
Loading more pages
Loading more pages

Sign up for email promotions.

Your information is safe with us and won't be shared.

Thank you for signing up!

 
©2003 - 2021 Grissett, LLC. All Rights Reserved.

By continuing to browse or by clicking Accept Cookies, you agree to the storing of cookies on your device necessary to provide you with the services available through our website.

    Accept   Privacy & Cookie Policy
Loading More Photos
Scroll To Top
Close Window
Loading
Close