Zen Cart Logo
Forums / Installing on a Linux/Unix Server / Moving Site from Sub-folder to Root

Moving Site from Sub-folder to Root

Views: 4,762

Results 1 to 11 of 11
1 Aug 2011, 11:49 PM
#1
willchen88 avatar

willchen88

New Zenner

Join Date:
Jul 2011
Posts:
10
Plugin Contributions:
0

Moving Site from Sub-folder to Root

I am using ZenCart Ver1.3.9. Had someone install my ZenCart and they put it on a Sub-Folder. I am using template 510. I have made all the appropriate changes and now need to move it to the Root directory so it will load immediately when one enters the site. I followed all the instruction I can find from the forum. http://www.zen-cart.com/forum/showthread.php?t=104968, and https://www.zen-cart.com/tutorials/index.php?article=122. These instructions did not work for me because I got stuck on that last bit of steps where it was not clearly stated in article=122. That part that needs to adjust configure.php and DIR_FS_SQL_CACHE. I also learned you need to login to your File Manager hosting server to enable WRITE for configure.php. There is also no Admin/Configuration/Session file/folder in version 1.3.9. as pointed by the instruction. Anyway, I was able to create that after I got info from the Zen Install files. I managed to move the site to the root folder and it works fine, but I cannot login to my Admin panel. My problem is that I cannot login to Admin panel after moving to the root. I followed the instruction, but apparently there are somethings else that needed to be done so that I can login to the Admin panel. The instructions left a lot of holes, which I call death holes. Please Zen Experts, please tell me exactly what I needed to do to fix this problem? I am willing to pay someone who can help me move my site from the subfolder to the root seamlessly. I want to make sure everything is done right so that my site will work normally.

1 Aug 2011, 11:53 PM
#2
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: Moving Site from Sub-folder to Root

Post both of your configure files here JUST XXX out your DB details

3 Aug 2011, 3:24 PM
#3
willchen88 avatar

willchen88

New Zenner

Join Date:
Jul 2011
Posts:
10
Plugin Contributions:
0

Re: Moving Site from Sub-folder to Root

This is what I got in my Configure.php file: Please help me make the proper adjustments.

<?php /** * @package Configuration Settings circa 1.3.9 * @copyright Copyright 2003-2010 Zen Cart Development Team * @copyright Portions Copyright 2003 osCommerce * @license <http://www.zen-cart.com/license/2_0.txt> GNU Public License V2.0 * File Built by zc_install on 2011-07-25 07:49:38 */ /*************** NOTE: This file is similar, but DIFFERENT from the "admin" version of configure.php. ***********/ /*************** The 2 files should be kept separate and not used to overwrite each other. ***********/ // Define the webserver and path parameters // HTTP_SERVER is your Main webserver: eg-http://www.your_domain.com // HTTPS_SERVER is your Secure webserver: eg-https://www.your_domain.com define('HTTP_SERVER', 'http://www.XXX.com'); define('HTTPS_SERVER', 'https://www.XXX.com'); // Use secure webserver for checkout procedure? define('ENABLE_SSL', 'false'); // NOTE: be sure to leave the trailing '/' at the end of these lines if you make changes! // * DIR_WS_* = Webserver directories (virtual/URL) // these paths are relative to top of your webspace ... (ie: under the public_html or httpdocs folder) define('DIR_WS_CATALOG', '/willchen/'); define('DIR_WS_HTTPS_CATALOG', '/willchen/'); define('DIR_WS_IMAGES', 'images/'); define('DIR_WS_INCLUDES', 'includes/'); 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', DIR_WS_CATALOG . 'pub/'); define('DIR_WS_TEMPLATES', DIR_WS_INCLUDES . 'templates/'); define('DIR_WS_PHPBB', '/'); // * DIR_FS_* = Filesystem directories (local/physical) //the following path is a COMPLETE path to your Zen Cart files. eg: /var/www/vhost/accountname/public_html/store/ define('DIR_FS_CATALOG', '/home/content/86/5516386/html/willchen/'); define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/'); define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/'); define('DIR_WS_UPLOADS', DIR_WS_IMAGES . 'uploads/'); define('DIR_FS_UPLOADS', DIR_FS_CATALOG . DIR_WS_UPLOADS); define('DIR_FS_EMAIL_TEMPLATES', DIR_FS_CATALOG . 'email/'); // define our database connection define('DB_TYPE', 'mysql'); define('DB_PREFIX', ''); define('DB_SERVER', 'changedadmin1234567.db.hostedresource.com'); define('DB_SERVER_USERNAME', 'changedadmin1234567'); define('DB_SERVER_PASSWORD', 'changedAdmin12345'); define('DB_DATABASE', 'admin1234567'); define('USE_PCONNECT', 'false'); define('STORE_SESSIONS', 'db'); // for STORE_SESSIONS, use 'db' for best support, or '' for file-based storage // The next 2 "defines" are for SQL cache support. // For SQL_CACHE_METHOD, you can select from: none, database, or file // If you choose "file", then you need to set the DIR_FS_SQL_CACHE to a directory where your apache // or webserver user has write privileges (chmod 666 or 777). We recommend using the "cache" folder inside the Zen Cart folder // ie: /path/to/your/webspace/public_html/zen/cache -- leave no trailing slash define('SQL_CACHE_METHOD', 'none'); define('DIR_FS_SQL_CACHE', '/home/content/86/5516386/html/willchen/cache'); // EOF
3 Aug 2011, 3:25 PM
#4
willchen88 avatar

willchen88

New Zenner

Join Date:
Jul 2011
Posts:
10
Plugin Contributions:
0

Re: Moving Site from Sub-folder to Root

What was the 2nd file you need?

3 Aug 2011, 3:45 PM
#5
willchen88 avatar

willchen88

New Zenner

Join Date:
Jul 2011
Posts:
10
Plugin Contributions:
0

Re: Moving Site from Sub-folder to Root

After moving all the files from the subfolder to the root folder.

All I needed to do is just change the settings in configure.php file. Is that all I need to do?

Do I need to make any changes in Zen-Cart Admin before moving the files?

Do I change the settings in configure.php file after the move or before?

3 Aug 2011, 3:56 PM
#6
willchen88 avatar

willchen88

New Zenner

Join Date:
Jul 2011
Posts:
10
Plugin Contributions:
0

Re: Moving Site from Sub-folder to Root

On my version 1.3.9, there is not admin/includes/configure.php file. I search everywhere and can't find it. I have been reading in the forum and most people say you have to edit admin/includes/configure.php, but on my version I cannot find this file. What should I do?

3 Aug 2011, 4:19 PM
#7
willchen88 avatar

willchen88

New Zenner

Join Date:
Jul 2011
Posts:
10
Plugin Contributions:
0

Re: Moving Site from Sub-folder to Root

https://www.zen-cart.com/tutorials/index.php?article=122

In this tutorial item no 5>
If you could not set the Session Write Directory in step 1 above, you can use a utility to do it for you. The goal is to make sure that the new path information (specifically the DIR_FS_SQL_CACHE setting in your new configure.php file) matches the Session Write Directory setting. If it doesn't, you may end up with difficulties logging in to the Admin area or maintaining login sessions in the store. The Fix Cache Key Utility from the Downloads > Troubleshooting Tools area on the main Zen Cart™ site will help you to do this if you need assistance. There is no harm running it to have it check that things are set properly. Be sure to delete the file from your server when done.

  1. I cannot find Session Write Directory. Where to find this?
  2. Cannot find "Fix Cache Key Utility."
3 Aug 2011, 4:25 PM
#8
willchen88 avatar

willchen88

New Zenner

Join Date:
Jul 2011
Posts:
10
Plugin Contributions:
0

Re: Moving Site from Sub-folder to Root

The only admin/includes/configure.php that I found is under zc_admin. Is this the file you guys were referring to?

3 Aug 2011, 4:41 PM
#9
willchen88 avatar

willchen88

New Zenner

Join Date:
Jul 2011
Posts:
10
Plugin Contributions:
0

Re: Moving Site from Sub-folder to Root

I feel like I am getting closer to finding an answer, but not quite, and I need confirmation before I try to move the site.

  1. If just editing the configure.php and zc_admin/includes/configure.php, then I can do that, but

  2. I am not sure about the "session write directory" settings? Do I ignore this and just make the necessary edits into those two files? Is that the only two files I need to worry about?

Please give me the final word on this. I promise not to post too many questions again.

3 Aug 2011, 5:02 PM
#10
willchen88 avatar

willchen88

New Zenner

Join Date:
Jul 2011
Posts:
10
Plugin Contributions:
0

Re: Moving Site from Sub-folder to Root

I was too impatient to wait for our Zen Master reply and went ahead to make the move on my site. I move the site to the root and updated the settings on the two files and so far it seems to be working. I may have solve the problem. However, I still would like to get confirmation from our Zen Masters as I think this experience can also help a lot of other folks. Thank you!

7 Aug 2011, 5:47 AM
#11
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: Moving Site from Sub-folder to Root

I move the site to the root and updated the settings on the two files

BUT you stated that you did not have the admin/includes/configure.php file - -
Replace "admin" with what ever you have renamed your admin directory to be