Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

problem connecting to admin section


Guest

Recommended Posts

hi - i have just installed "administrators 1.2.2" for login/logoff to admin section. now its working just fine on my localhost, but when i try to access it on my web server, i get this prob:

 

1046 - No Database Selected

 

select configuration_key as cfgKey, configuration_value as cfgValue from configuration

 

 

i simply copied the admin folder (which i updated on my computer) to the server. any ideas why it won't work. is there a separate config file for the admin section - as my catalog still works just fine.

 

thanks tim

Link to comment
Share on other sites

ok - the one on my localhost is:

 

// define our webserver variables

// FS = Filesystem (physical)

// WS = Webserver (virtual)

 define('HTTP_SERVER', ''); // eg, http://localhost or - https://localhost should not be NULL for productive servers

 define('HTTP_CATALOG_SERVER', '');

 define('HTTPS_CATALOG_SERVER', '');

 define('ENABLE_SSL_CATALOG', 'false'); // secure webserver for catalog module

 define('DIR_FS_DOCUMENT_ROOT', $DOCUMENT_ROOT); // 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', '/paul/catalog/admin/');

 define('DIR_FS_ADMIN', DIR_FS_DOCUMENT_ROOT . DIR_WS_ADMIN);

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

 define('DIR_FS_CATALOG', DIR_FS_DOCUMENT_ROOT . DIR_WS_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/');



// define our database connection

 define('DB_SERVER', '');

 define('DB_SERVER_USERNAME', 'mysql');

 define('DB_SERVER_PASSWORD', '');

 define('DB_DATABASE', 'catalog');

 define('USE_PCONNECT', 'false');

 define('STORE_SESSIONS', '');

 

 

now this works just fine on my computer.

 

and the one for the web server

 

 

// define our webserver variables

// FS = Filesystem (physical)

// WS = Webserver (virtual)

 define('HTTP_SERVER', ''); // eg, http://localhost or - https://localhost should not be NULL for productive servers

 define('HTTP_CATALOG_SERVER', '');

 define('HTTPS_CATALOG_SERVER', '');

 define('ENABLE_SSL_CATALOG', 'false'); // secure webserver for catalog module

 define('DIR_FS_DOCUMENT_ROOT', $DOCUMENT_ROOT); // 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', '/paul/catalog/admin/');

 define('DIR_FS_ADMIN', DIR_FS_DOCUMENT_ROOT . DIR_WS_ADMIN);

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

 define('DIR_FS_CATALOG', DIR_FS_DOCUMENT_ROOT . DIR_WS_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/');



// define our database connection

 define('DB_SERVER', ''localhost'); ');

 define('DB_SERVER_USERNAME', 'timheath_root');

 define('DB_SERVER_PASSWORD', '*****');

 define('DB_DATABASE', 'timheath_root');

 define('USE_PCONNECT', 'false');

 define('STORE_SESSIONS', '');

 

 

initially - i just copied over the file from my localhost admin folder - it couldn't connect, so i filled in the info from the catalog/includes/configure.php in regard to db_server_* stuff.

Link to comment
Share on other sites

I don't see how it worked since you don't have any of the URL defines filed in. LIke:

 

  define('HTTP_SERVER', ''); // eg, http://localhost or - https://localhost should not be NULL for productive servers 

 define('HTTP_CATALOG_SERVER', ''); 

 define('HTTPS_CATALOG_SERVER', '');

 

and

 

  define('HTTP_SERVER', ''); // eg, http://localhost or - https://localhost should not be NULL for productive servers 

 define('HTTP_CATALOG_SERVER', ''); 

 define('HTTPS_CATALOG_SERVER', '');

 

You must have these filed in if you're outside of localhost.

Steve

-------------------------

Link to comment
Share on other sites

I need to preview these before posting. You must have the defines filled in on you production server.

 

example:

 

  define('HTTP_SERVER', 'http://www.yourdomain.com'); // eg, http://localhost or - https://localhost should not be NULL for productive servers 

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

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

Steve

-------------------------

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...