Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

2 Errors I can't fix.. Help please


petal

Recommended Posts

Posted

1.

 

Well I thought all was well but when I click on anything that seems to need the access the MySQL db, I get the error below..

 

Warning: mysql_connect(): Access denied for user: 'apache@localhost' (Using password: NO) in /home/httpd/vhosts/mysite.com/httpsdocs/store/catalog/includes/functions/database.php on line 19
Unable to connect to database server!

 

I have checked the config files both in the catalog/includes and the admin/includes on both side (httpdocs and httpsdocs) and the password for the database is there.

 

AND

 

2.

 

In addition, I created the backups and cache directories, chmod to 755 and I get and error at top of page that says these directories are not writable.

 

Do I need to put a file in them? Any suggestions for either problem (or better both issues??) THANK YOU so much for your help!

 

Petal

Posted

Well, the first error strongly suggests that osC doesn't think you set a password - and maybe not a username? Is localhost right for the server?

 

Depending on how your server is configured, 755 may not work - you may need 777. I strongly recommend putting such directories outside the web-accessible area of your site (above public_html or whatever...)

Posted

Thank's for the quick response! I thought of that right after I posted and went and set the 2 directories to 777 and that works.. duh. I just figured 755 was just as good.

 

If I moved my cache and backups folder up to the same level as my httpdocs (so I see them all in the same place) that is a safe place?

 

RE: db error above - Yeah, according to the hosting company that is what they told me and that is the only way I was able to install OSC.. nothing else worked. And the username and passwords / and db name are correct - the config files are show them. ... Any suggestions on what I should do?

 

PS>> I am going to install the PayPal mod, will that make a difference? I was trying to make sure all I had done so far was working fine.

 

Thanks!

Petal

Posted

BTW, it looks like I can't create a new directory at my root level (on the same level as my httpdocs and httpsdocs dir's .. I originally tried to put the cache dir in httpsdoc but OsC didn't like that very much.

 

petal

Posted

The same level as httpdocs works fine - the key is that they should not be under httpdocs. BTW, I would recommend against using the bacjup directory, even though you can create it. Instead, use the option to back up your database to a local ZIP file and keep the copy safe. Otherwise, if you lose your files on the host, you've lost the database too.

 

I'm concerned about the "using password: NO" in the error. That suggests that osC isn't seeing the password. Are you sure that the copy of configure.php on the server has the password? No spaces at the end of any of the defines?

Posted

Since I had to load OSC in both the http and https directories, do the config files on both sides need to match? And no there are no spaces, etc by the user or pass.

 

And the server will not let me put the cache dir at the root, and I tried to put it in the https doc and OSC doesn't like that.

 

So I am continuing to work on it and any suggestions will be greatly appreciated.

 

Thanks,

Petal

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...