Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Move osc one level up the directory tree...


wangchao

Recommended Posts

Posted

Hi, guys.

 

Have any of you done this before? I have to do this because various seo tips suggest to put the store at the root directory. I have taken the following steps, yet it is not completed yet.

 

1) backup the entire content under http://www.myname.com/catalog using ws_ftp, and SQL file from CPanel.

2) make a copy of this backup, and work on this copy.

3) in visual C++ IDE, search all the 'catalog' in this new copy, remove them if there are in html tags.

4) upload the changes onto the root directory of http://www.myname.com/

5) in Cpanel, removed the redirect links to /catalog, which I set before.

 

now, I can point the ie to url http://www.myname.com/ to get it running. However, the links under categories still show the old directory which is http://www.myname.com/catalog/xxxxxx.html. As SEO contributions are installed, I don't know which directory this URL is referencing. The old one or the new one one level up from the root? I didn't have a test to figure out this.

 

also, I cannot login to admin area from http://www.myname.com/admin. Instead, I can login from http://www.myname.com/catalog/admin.

 

anyone has experience in fixing this problem?

 

 

 

Thank you millions times!

David

-David Wang

Posted
now, I can point the ie to url http://www.myname.com/ to get it running. However, the links under categories still show the old directory which is http://www.myname.com/catalog/xxxxxx.html. As SEO contributions are installed, I don't know which directory this URL is referencing. The old one or the new one one level up from the root? I didn't have a test to figure out this.

 

also, I cannot login to admin area from http://www.myname.com/admin. Instead, I can login from http://www.myname.com/catalog/admin.

 

anyone has experience in fixing this problem?

Thank you millions times!

David

 

STEP 1.

 

copy everything to your "http://www.myname.com/"'>http://www.myname.com/" EXCLUDING your calalog folder.

then copy the contents of catalog to your "http://www.myname.com/"'>http://www.myname.com/"

Now you should have "http://www.myname.com/includes"'>http://www.myname.com/includes"

 

SETP 2.

In /includes/ edit --> configure.php

Make sure everything is defined as follows:

 

define('HTTP_SERVER', 'http://www.myname.com'); // eg, http://localhost

define('HTTPS_SERVER', 'https://www.myname.com'); // eg, https://localhost

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

define('HTTP_COOKIE_DOMAIN', ''); // sorry I am not sure here, as I to am new at this.

define('HTTPS_COOKIE_DOMAIN', '');

define('HTTP_COOKIE_PATH', '');

define('HTTPS_COOKIE_PATH', '');

define('DIR_WS_HTTP_CATALOG', '/'); //set it to "/" so that the website will recognise www.myname.com

define('DIR_WS_HTTPS_CATALOG', '/'); //set it to "/"

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', dirname($HTTP_SERVER_VARS['SCRIPT_FILENAME']));

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

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

 

// define our database connection

define('DB_SERVER', 'www.myname.com');

define('DB_SERVER_USERNAME', 'urusrname'); // Change this to your Username

define('DB_SERVER_PASSWORD', 'urpword'); // Change this to your Password

define('DB_DATABASE', 'urdatabase'); // Change this to your database name

define('USE_PCONNECT', 'false');

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

 

Step 3.

open http://www.myname.com/admin/includes/ edit --> configure.php

Make sure everything is defined as follows:

 

 

define('HTTP_SERVER', 'http://www.myname.com'); // eg, http://localhost

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

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

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

define('DIR_FS_DOCUMENT_ROOT', $DOCUMENT_ROOT);

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

define('DIR_FS_ADMIN', DIR_FS_DOCUMENT_ROOT . DIR_WS_ADMIN);

define('DIR_WS_CATALOG', '/'); //set it to "/"

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', 'www.myname.com');

define('DB_SERVER_USERNAME', 'urusrname'); // Change this to your Username

define('DB_SERVER_PASSWORD', 'urpword'); // Change this to your Password

define('DB_DATABASE', 'urdatabase'); // Change this to your database name

define('USE_PCONNECT', 'false');

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

 

 

Everything should work.

:D

Archived

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

×
×
  • Create New...