Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Admin section suddenly not accessible - gives a 404 - Not really sure why...


dleifm

Recommended Posts

Howdy folks,

 

I'm having a wee bit of trouble accessing the admin section. Everything's been working fine for the last 6 months and then, suddenly the admin section of OSCommerce is no longer accessible... it gives a 404 page: http://www.petitepassengers.com/catalog/admin/

 

I've searched the OSC forum for possible solutions, tried a number of them, but haven't been able to figure out a solution.

 

So... can anyone help? If it might be useful, my /catalog/admin/includes/configure.php file looks like so:

 

// Define the webserver and path parameters
// * DIR_FS_* = Filesystem directories (local/physical)
// * DIR_WS_* = Webserver directories (virtual/URL)
 define('HTTP_SERVER', 'http://www.petitepassengers.com'); // eg, http://localhost - should not be empty for productive servers
 define('HTTP_CATALOG_SERVER', 'http://www.petitepassengers.com');
 define('HTTPS_CATALOG_SERVER', '');
 define('ENABLE_SSL_CATALOG', 'false'); // secure webserver for catalog module
 define('DIR_FS_DOCUMENT_ROOT', '/home/petite/public_html/catalog/'); // where the pages are located on the server
 define('DIR_WS_ADMIN', '/catalog/admin/'); // absolute path required
 define('DIR_FS_ADMIN', '/home/petite/public_html/catalog/admin/'); // absolute pate required
 define('DIR_WS_CATALOG', '/catalog/'); // absolute path required
 define('DIR_FS_CATALOG', '/home/petite/public_html/catalog/'); // absolute path required
 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'); // eg, localhost - should not be empty for productive servers
 define('DB_SERVER_USERNAME', 'petite_admin');
 define('DB_SERVER_PASSWORD', 'sunscreen');
 define('DB_DATABASE', 'petite_modx');
 define('USE_PCONNECT', 'false'); // use persisstent connections?
 define('STORE_SESSIONS', 'mysql'); // leave empty '' for default handler or set to 'mysql'
?>

 

I really don't have a clue as to what the problem might be, so any advice would be much appreciated.

 

Cheers!

Link to comment
Share on other sites

Well it's a 404 message ( means page not found) try reloading the page! did your host make any changes without telling you? probably that happens a lot.

 

now that the whole world knows your MySql password you should probably change it.

Link to comment
Share on other sites

define('DIR_WS_CATALOG', '/catalog/'); // absolute path required <-----------------------------

define('DIR_FS_CATALOG', '/home/petite/public_html/catalog/'); // absolute path required

 

You should change your database username and password. The world now nows what it is.

 

Change it in phpmyadmin and both the configure.php files.

Link to comment
Share on other sites

OK - database username/password have now been changed. Thanks for the advice there. :blush:

 

---

 

chipshot: reloading the page doesn't help.

did your host make any changes without telling you? probably that happens a lot.

 

I'm not sure, but I'll check with them - thanks for the tip.

 

---

 

Coopco:

define('DIR_WS_CATALOG', '/catalog/'); // absolute path required <-----------------------------

 

I've changed this path to '/home/petite/public_html/catalog/admin/' but it doesn't seem to make a difference.

 

---

 

Now that I've changed the database user/pass, /catalog/admin/ no longer gives me a 404. Now it says this:

 

Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator, [email protected] and inform them of the time the error occurred, and anything you might have done that may have caused the error.

More information about this error may be available in the server error log.

Additionally, a 500 Internal Server Error error was encountered while trying to use an ErrorDocument to handle the request.

 

Any further ideas?

Link to comment
Share on other sites

  • 2 years later...

define('DIR_WS_CATALOG', '/catalog/'); // absolute path required <-----------------------------

define('DIR_FS_CATALOG', '/home/petite/public_html/catalog/'); // absolute path required

 

You should change your database username and password. The world now nows what it is.

 

Change it in phpmyadmin and both the configure.php files.

 

 

My oscommerce site was working at www.waterandairhobbies.com/MyStore/index.php but when the host changed something in the server to redirect www.waterandairhobbies.com to display my oscommerce website whenever someone went to www.waterandairhobbies.com I could no longer get into the admin page. You can see the site just fine but my log in does not work. I now go to www.waterandairhobbies.com/admin/login.php but when i use a password it drops me at www.waterandairhobbies.com/MyStore/admin.php 404 not found. The following is my code. I am not sure how this last guy "reloaded" and got it fixed. Any suggestions?

 

<?php
 define('HTTP_SERVER', 'http://waterandairhobbies.com');
 define('HTTP_CATALOG_SERVER', 'http://waterandairhobbies.com');
 define('HTTPS_CATALOG_SERVER', 'https://waterandairhobbies.com');
 define('ENABLE_SSL_CATALOG', false);
 define('DIR_FS_DOCUMENT_ROOT', '/home/watera6/public_html/MyStore/');
 define('DIR_WS_ADMIN', '/MyStore/admin/');
 define('DIR_FS_ADMIN', '/home/watera6/public_html/MyStore/admin/');
 define('DIR_WS_CATALOG', '/MyStore/');
 define('DIR_FS_CATALOG', '/home/watera6/public_html/MyStore/');
 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

My oscommerce site was working at www.waterandairhobbies.com/MyStore/index.php but when the host changed something in the server to redirect www.waterandairhobbies.com to display my oscommerce website whenever someone went to www.waterandairhobbies.com I could no longer get into the admin page. You can see the site just fine but my log in does not work. I now go to www.waterandairhobbies.com/admin/login.php but when i use a password it drops me at www.waterandairhobbies.com/MyStore/admin.php 404 not found. The following is my code. I am not sure how this last guy "reloaded" and got it fixed. Any suggestions?

 

<?php
 define('HTTP_SERVER', 'http://waterandairhobbies.com');
 define('HTTP_CATALOG_SERVER', 'http://waterandairhobbies.com');
 define('HTTPS_CATALOG_SERVER', 'https://waterandairhobbies.com');
 define('ENABLE_SSL_CATALOG', false);
 define('DIR_FS_DOCUMENT_ROOT', '/home/watera6/public_html/MyStore/');
 define('DIR_WS_ADMIN', '/MyStore/admin/');
 define('DIR_FS_ADMIN', '/home/watera6/public_html/MyStore/admin/');
 define('DIR_WS_CATALOG', '/MyStore/');
 define('DIR_FS_CATALOG', '/home/watera6/public_html/MyStore/');
 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/');

Remove the "MyStore/" on every line in the /admin/configure.php file above.

 

AND, you should apply some security to your store (see my sig,) like applying directory security to your admin directory, and changing the name of the admin directory to something obscure.

Community Bootstrap Edition, Edge

 

Avoid the most asked question. See How to Secure My Site and How do I...?

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...