Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

can't access admin tool


ausipodskins

Recommended Posts

I have succesfully completed my installation. Now, when I press the admin tool button on the last page of the installer I get the following message:

 

Warning: Access denied for user: 'mysql@localhost' (Using password: NO) in /home/httpd/vhosts/freepgs.com/httpdocs/piquet/catalog/admin/includes/functions/database.php on line 19

 

Warning: MySQL Connection Failed: Access denied for user: 'mysql@localhost' (Using password: NO) in /home/httpd/vhosts/freepgs.com/httpdocs/piquet/catalog/admin/includes/functions/database.php on line 19

Unable to connect to database server!

 

I suspect that this means that the database on my server can't be accessed without the log/pass. where do I put this information? No dialogue box asking for it came up.

 

thanks again for any assistance.

Link to comment
Share on other sites

Your hosting provider most likely has assigned a database user name and password for you and given server information. You'll find this somewhere in your sign up docs.

 

You need to take this information and put it in the configuration files

 

catalog/includes/configure.php and catalog/admin/includes/configure.php

 

// define our database connection

define('DB_SERVER', ''); // eg, localhost - should not be empty for productive servers

define('DB_SERVER_USERNAME', '');

define('DB_SERVER_PASSWORD', '');

define('DB_DATABASE', 'osCommerce');

define('USE_PCONNECT', 'false'); // use persistent connections?

define('STORE_SESSIONS', ''); // leave empty '' for default handler or set to 'mysql'

Local: Mac OS X 10.5.8 - Apache 2.2/php 5.3.0/MySQL 5.4.10 • Web Servers: Linux

Tools: BBEdit, Coda, Versions (Subversion), Sequel Pro (db management)

Link to comment
Share on other sites

I would presume that your confiure.php database information looks something like this

// define our database connection
define('DB_SERVER', 'localhost'); // eg, localhost - should not be empty for productive servers
define('DB_SERVER_USERNAME', 'mysql');
define('DB_SERVER_PASSWORD', '');
define('DB_DATABASE', 'osCommerce');
define('USE_PCONNECT', 'false'); // use persistent connections?
define('STORE_SESSIONS', ''); // leave empty '' for default handler or set to 'mysql'

at the moment and as AlanR has said this may be the wrong information

No longer giving free advice. Please place deposit in meter slot provided.  Individual: [=] SME: [==] Corporation: [===]
If deposit does not fit one of the slots provided then you are asking too much! :P

Is your Osc dated try Phoenix  raising oscommerce from the ashes.

Link to comment
Share on other sites

BINGO

 

You were correct 241 but what I had didn't include the comments. hope I'm running the correct version (osCommerce 2.2-MS2)

 

Anyway, the admin tool loads now.

 

thanks again guys (until next time)

Link to comment
Share on other sites

It's me again.

 

although the page for the admin tools loads, I'm unable to load anything from the various links. In every case it just says :

 

HTTP 404 - Page Not Found

 

Sorry, this page is not available.

Link to comment
Share on other sites

your paths are wrong in your configure.php files post them and I will correct or pm me with the information

can you also include an absolute path something like user/www/public_html/

No longer giving free advice. Please place deposit in meter slot provided.  Individual: [=] SME: [==] Corporation: [===]
If deposit does not fit one of the slots provided then you are asking too much! :P

Is your Osc dated try Phoenix  raising oscommerce from the ashes.

Link to comment
Share on other sites

catalog/includes/configure.php this file is for the catalog side

admin/includes/configure.php this file is for the admin side

No longer giving free advice. Please place deposit in meter slot provided.  Individual: [=] SME: [==] Corporation: [===]
If deposit does not fit one of the slots provided then you are asking too much! :P

Is your Osc dated try Phoenix  raising oscommerce from the ashes.

Link to comment
Share on other sites

thanks 241 for the revisions.

 

still got problems.

 

when I go to URL: <home>/piquet/catalog/

 

or URL: <home>/piquet/catalog/admin/index.php

 

I get the following error messages, respectively:

 

Parse error: parse error in /home/httpd/vhosts/freepgs.com/httpdocs/piquet/catalog/includes/configure.php on line 18

 

Fatal error: Failed opening required 'DIR_WS_INCLUDESfilenames.php' (include_path='.:/usr/share/pear') in /home/httpd/vhosts/freepgs.com/httpdocs/piquet/catalog/includes/application_top.php on line 53

 

 

Parse error: parse error in /home/httpd/vhosts/freepgs.com/httpdocs/piquet/catalog/admin/includes/configure.php on line 17

 

Fatal error: Failed opening required 'DIR_WS_INCLUDESfilenames.php' (include_path='.:/usr/share/pear') in /home/httpd/vhosts/freepgs.com/httpdocs/piquet/catalog/admin/includes/application_top.php on line 44

 

I am so confused still.

 

Pk

Link to comment
Share on other sites

can you post the /catalog/includes/configure.php line 18 and /catalog/admin/includes/configure.php line 17 the error is showing no / between 'DIR_WS_INCLUDESfilenames.php'

No longer giving free advice. Please place deposit in meter slot provided.  Individual: [=] SME: [==] Corporation: [===]
If deposit does not fit one of the slots provided then you are asking too much! :P

Is your Osc dated try Phoenix  raising oscommerce from the ashes.

Link to comment
Share on other sites

here is /catalog/includes/configure.php minus the security stuff. (sorry I couldn't figure out which line I should show you)

 

// Define the webserver and path parameters

// * DIR_FS_* = Filesystem directories (local/physical)

// * DIR_WS_* = Webserver directories (virtual/URL)

define('HTTP_SERVER', 'http://www.freepgs.com'); // eg, http://localhost - should not be empty for productive servers

define('HTTPS_SERVER', 'https://www.freepgs.com'); // eg, https://localhost - should not be empty for productive servers

define('ENABLE_SSL', true); // secure webserver for checkout procedure?

define('HTTP_COOKIE_DOMAIN', 'freepgs.com'); ??// removed the www.

define('HTTPS_COOKIE_DOMAIN', 'freepgs.com');? // removed the www.

define('HTTP_COOKIE_PATH', '/piquet/catalog/');

define('HTTPS_COOKIE_PATH', '/piquet/catalog/');

define('DIR_WS_HTTP_CATALOG', '/piquet/catalog/');

define('DIR_WS_HTTPS_CATALOG', '/piquet/catalog/');

define('DIR_WS_IMAGES', 'images/');

define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/');

define('DIR_WS_INCLUDES', 'includes/');

define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/');

define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/');

define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/');

define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/');

define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/');

 

define('DIR_WS_DOWNLOAD_PUBLIC', 'pub/');

define('DIR_FS_CATALOG', '/home/httpd/vhosts/freepgs.com/httpdocs/piquet/catalog/');

define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/');

define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/');

 

here is /catalog/admin/includes/configure.php

 

// define our webserver variables

// FS = Filesystem (physical)

// WS = Webserver (virtual)

define('HTTP_SERVER', 'http://www.freepgs.com'); // eg, http://localhost or - https://localhost

should not be NULL for productive servers

define('HTTP_CATALOG_SERVER', 'http://www.freepgs.com');

define('HTTPS_CATALOG_SERVER', 'https://www.freepgs.com');

define('ENABLE_SSL_CATALOG', 'false'); // secure webserver for catalog?? //? you can change this to true if you want module

define('DIR_FS_DOCUMENT_ROOT', '/home/httpd/vhosts/freepgs.com/httpdocs/piquet/catalog/'); // where your pages are located on the server. if $DOCUMENT_ROOT doesnt suit you, replace with your local path. (eg, /usr/local/apache/htdocs)

define('DIR_WS_ADMIN', '/piquet/catalog/admin/');

define('DIR_FS_ADMIN', '/home/httpd/vhosts/freepgs.com/httpdocs/piquet/catalog/admin/');

define('DIR_WS_CATALOG', '/piquet/catalog/');

define('DIR_FS_CATALOG', '/home/httpd/vhosts/freepgs.com/httpdocs/piquet/catalog/');

?//? if you find a problem in admin then change this line to '/home/httpd/vhosts/freepgs.com/httpdocs/piquet/catalog');

 

define('DIR_WS_IMAGES', 'images/');

define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/');

define('DIR_WS_CATALOG_IMAGES', DIR_WS_CATALOG . 'images/');

define('DIR_WS_INCLUDES', 'includes/');

define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/');

define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/');

define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/');

define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/');

define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/');

define('DIR_WS_CATALOG_LANGUAGES', DIR_WS_CATALOG .'includes/languages/');

define('DIR_FS_CATALOG_LANGUAGES', DIR_FS_CATALOG .'includes/languages/');

define('DIR_FS_CATALOG_IMAGES', DIR_FS_CATALOG . 'images/');

define('DIR_FS_CATALOG_MODULES', DIR_FS_CATALOG . 'includes/modules/');

define('DIR_FS_BACKUP', DIR_FS_ADMIN . 'backups/');

Link to comment
Share on other sites

Ok I will concentrate on the catalog first as I only removed the www. in this file

 

// Define the webserver and path parameters
// * DIR_FS_* = Filesystem directories (local/physical)
// * DIR_WS_* = Webserver directories (virtual/URL)
define('HTTP_SERVER', 'http://www.freepgs.com'); // eg, http://localhost - should not be empty for productive servers
define('HTTPS_SERVER', 'https://www.freepgs.com'); // eg, https://localhost - should not be empty for productive servers
define('ENABLE_SSL', false); // secure webserver for checkout procedure?
define('HTTP_COOKIE_DOMAIN', 'www.freepgs.com');
define('HTTPS_COOKIE_DOMAIN', 'www.freepgs.com');
define('HTTP_COOKIE_PATH', '/piquet/catalog/');
define('HTTPS_COOKIE_PATH', '/piquet/catalog/');
define('DIR_WS_HTTP_CATALOG', '/piquet/catalog/');
define('DIR_WS_HTTPS_CATALOG', '/piquet/catalog/');
define('DIR_WS_IMAGES', 'images/');
define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/');
define('DIR_WS_INCLUDES', 'includes/');
define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/');
define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/');
define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/');
define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/');
define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/');

define('DIR_WS_DOWNLOAD_PUBLIC', 'pub/');
define('DIR_FS_CATALOG', '/home/httpd/vhosts/freepgs.com/httpdocs/piquet/catalog/');
define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/');
define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/');

backup your files then change the cookie domain back to www.freepgs.com and SSL to false for the moment, make sure that any comments do not spill onto another line if they do then where they spill over to another line comment them out // or for the moment remove all the comments.

 

I am changing SSL to false for the moment in order to simplify things once everything is working then SSL can be set to true

No longer giving free advice. Please place deposit in meter slot provided.  Individual: [=] SME: [==] Corporation: [===]
If deposit does not fit one of the slots provided then you are asking too much! :P

Is your Osc dated try Phoenix  raising oscommerce from the ashes.

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...