Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Error 403 -- can't access files


StephenGlynn

Recommended Posts

I've just installed osCommerce on my home pc (Windows XP). The installation appears to have gone OK -- I've got as far as step 7, which tells me that "the configuration was successful" but when I click either "catalog" or "administration tool" I'm told

 

"You don't have permission to access /catalog/install/://localhost/catalog/admin/index.php on this server"

or

You don't have permission to access /catalog/install/://localhost/catalog/index.php on this server"

 

I see from reading back in this forum that Siavash had what seems to be an identical problem a couple of weeks ago, but I can't understand the fix he came up with.

 

What files should I be looking at and what should I edit in them? I've followed all the defaults in the installation and MySQL is letting me look at the tables in osCommerce.

 

Can anyone help?

 

Steve

Link to comment
Share on other sites

hi steve,

 

1. right-click the catalog folder and uncheck the read-only box and make sure that you apply the unckecking to all subfolders and files in catalog. i know it looks as if it is till checked but if you look at the files you will realize that they are all unchecked. just in case why not try the following code to adjust the permissions:

 

<?php 
chmod('includes/configure.php', 0644); 
?>

 

call it whatever you fancy, save it as .php, put this in your htdocs and run it in the browser. nothing visual will happen but you have set your access permission/chomd you config file to 644.

 

read the installation docs here http://wiki.oscommerce.com/docsInstallNew and this bug report might help http://www.oscommerce.com/community/bugs,1585

 

2. copy and paste the following configure code in notepad and save as php i.e configure.php and replace the current configure.php you are using in catalog/include . do the same with the configure.php in catalog/admin/include.

open your browser and start installation again.

 

3. in case this didn't work. why not do a clean installation. completely remove your oscommerce from your htdocs and put them there again from your oscommerce zipfile. it only take a couple of minutes. and make the necessary changes to the config files.

 

catalog/include/configure.php

 

<?php
/*
 osCommerce, Open Source E-Commerce Solutions
 http://www.oscommerce.com

 Copyright (c) 2003 osCommerce

 Released under the GNU General Public License
*/

// Define the webserver and path parameters
// * DIR_FS_* = Filesystem directories (local/physical)
// * DIR_WS_* = Webserver directories (virtual/URL)
 define('HTTP_SERVER', 'http://localhost'); // eg, http://localhost - should not be empty for productive servers
 define('HTTPS_SERVER', ''); // eg, https://localhost - should not be empty for productive servers
 define('ENABLE_SSL', false); // secure webserver for checkout procedure?
 define('HTTP_COOKIE_DOMAIN', 'localhost');
 define('HTTPS_COOKIE_DOMAIN', '');
 define('HTTP_COOKIE_PATH', '/catalog/');
 define('HTTPS_COOKIE_PATH', '');
 define('DIR_WS_HTTP_CATALOG', 'localhost/catalog/');
 define('DIR_WS_HTTPS_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', 'C:/Program Files/Apache Group/Apache2/htdocs/catalog/');
 define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/');
 define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/');

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

 

and here is catalog/admin/lnclude/config.php

 

<?php
/*
 osCommerce, Open Source E-Commerce Solutions
 http://www.oscommerce.com

 Copyright (c) 2003 osCommerce

 Released under the GNU General Public License
*/

// Define the webserver and path parameters
// * DIR_FS_* = Filesystem directories (local/physical)
// * DIR_WS_* = Webserver directories (virtual/URL)
 define('HTTP_SERVER', 'http://localhost'); // eg, http://localhost - should not be empty for productive servers
 define('HTTP_CATALOG_SERVER', 'http://localhost');
 define('HTTPS_CATALOG_SERVER', '');
 define('ENABLE_SSL_CATALOG', 'false'); // secure webserver for catalog module
 define('DIR_FS_DOCUMENT_ROOT', 'C:/Program Files/Apache Group/Apache2/htdocs/catalog/'); // where the pages are located on the server
 define('DIR_WS_ADMIN', 'http://localhost/catalog/admin/'); // absolute path required
 define('DIR_FS_ADMIN', 'C:/Program Files/Apache Group/Apache2/htdocs/catalog/admin/'); // absolute pate required
 define('DIR_WS_CATALOG', 'http://localhost/catalog/'); // absolute path required
 define('DIR_FS_CATALOG', 'C:/Program Files/Apache Group/Apache2/htdocs/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', 'root');
 define('DB_SERVER_PASSWORD', '');
 define('DB_DATABASE', 'osCommerce');
 define('USE_PCONNECT', 'true'); // use persisstent connections?
 define('STORE_SESSIONS', 'mysql'); // leave empty '' for default handler or set to 'mysql'
?>

 

 

this worked for me. i don't see why it shouldn't for you!

 

good luck.

Did you try? Did you fail? No matter! Try again. Fail again! But fail better!

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...