Page 1 of 1

Transferring Site to New Host

Posted: Wed Mar 16, 2022 11:31 pm
by kriswaide
Hello - we are moving our site to a new host and currently we are in a test environment.
We have OpenCart 2.3.0.2 and we have a backup of databases and such from current host.
Our site will "run" in the test environment, however all the images in our catalog do not appear, but other images - non catalog related, do appear.
All data for our products show - name, description, etc. - but no images appear, no do the images appear in our modules on the front page of the website.
We know very little about OpenCart as this was set up by someone prior to our time.

Config.php files for both main and admin point to correct folders, but nothing is working.
Is it imperative that the root folder be labeled public_html/ ? Currently everything is pointing to html/ but nothing is showing images.
When trying to add an image in the image manager we get the directory does not exist error.
Is there something we need to look at or something we are missing?

Re: Transferring Site to New Host

Posted: Thu Mar 17, 2022 12:19 am
by cyclops12
Probably trying to read the images from the image/cache folder
Try renaming the image/cache folder to "cache_old" first and see if that works
If not you can always revert back

Re: Transferring Site to New Host

Posted: Thu Mar 17, 2022 12:41 am
by straightlight
Ensure that your FTP image path matches with the database image paths from your product and produict_image tables along with both config.php files.

In the meantime, please post your Server Error Logs.

Re: Transferring Site to New Host

Posted: Thu Mar 17, 2022 1:50 am
by kriswaide
Does this help?
Cannot serve directory /SITENAME/html/image/: No matching DirectoryIndex (index.php,index.html,index.htm,default.html,default.htm,index.php,index.php) found, and server-generated directory index forbidden by Options directive, referer https://SITENAME/index.php?route=common/home

Actual site name replaced with /SITENAME/ - but is any of this helpful?

The changing of the image cache folder to cache_old did not help.

Re: Transferring Site to New Host

Posted: Thu Mar 17, 2022 2:19 am
by cyclops12
Make sure you check all the files as stated by Straightlight above
Also check htaccess for correct paths

Re: Transferring Site to New Host

Posted: Fri Mar 18, 2022 1:40 am
by kriswaide
I am putting in the configs minus the database info, hoping someone may see an error or something?
Site will load some basic images - however, catalog is not pulling at all in our test environment, and we cannot add any images either, we think the directory is improperly defined...?

Root config.php
<?php
// HTTP
define('HTTP_SERVER', 'https://73ed6e063f.nxcli.net/');

// HTTPS
define('HTTPS_SERVER', 'https://73ed6e063f.nxcli.net/');

// DIR
define('DIR_APPLICATION', '/home/a2eefcc9/73ed6e063f.nxcli.net/html/catalog/');
define('DIR_SYSTEM', '/home/a2eefcc9/73ed6e063f.nxcli.net/html/system/');
define('DIR_IMAGE', '/home/a2eefcc9/73ed6e063f.nxcli.net/html/image/');
define('DIR_LANGUAGE', '/home/a2eefcc9/73ed6e063f.nxcli.net/html//catalog/language/');
define('DIR_TEMPLATE', '/home/a2eefcc9/73ed6e063f.nxcli.net/html/catalog/view/theme/');
define('DIR_CONFIG', '/home/a2eefcc9/73ed6e063f.nxcli.net/html/system/config/');
define('DIR_CACHE', '/home/a2eefcc9/73ed6e063f.nxcli.net/html/system/storage/cache/');
define('DIR_DOWNLOAD', '/home/a2eefcc9/73ed6e063f.nxcli.net/html/system/storage/download/');
define('DIR_LOGS', '/home/a2eefcc9/73ed6e063f.nxcli.net/html/system/storage/logs/');
define('DIR_MODIFICATION', '/home/a2eefcc9/73ed6e063f.nxcli.net/html/system/storage/modification/');
define('DIR_UPLOAD', '/home/a2eefcc9/73ed6e063f.nxcli.net/html/system/storage/upload/');

admin.config.php
<?php
// HTTP
define('HTTP_SERVER', 'https://73ed6e063f.nxcli.net/admin/');
define('HTTP_CATALOG', 'https://73ed6e063f.nxcli.net/');

// HTTPS
define('HTTPS_SERVER', 'https://73ed6e063f.nxcli.net/admin/');
define('HTTPS_CATALOG', 'https://73ed6e063f.nxcli.net/');

// DIR
define('DIR_APPLICATION', '/home/a2eefcc9/73ed6e063f.nxcli.net/html/admin/');
define('DIR_SYSTEM', '/home/a2eefcc9/73ed6e063f.nxcli.net/html/system/');
define('DIR_IMAGE', '/home/a2eefcc9/73ed6e063f.nxcli.net/html/image/');
define('DIR_LANGUAGE', '/home/a2eefcc9/73ed6e063f.nxcli.net/html/admin/language/');
define('DIR_TEMPLATE', '/home/a2eefcc9/73ed6e063f.nxcli.net/html/admin/view/template/');
define('DIR_CONFIG', '/home/a2eefcc9/73ed6e063f.nxcli.net/html/system/config/');
define('DIR_CACHE', '/home/a2eefcc9/73ed6e063f.nxcli.net/html/system/storage/cache/');
define('DIR_DOWNLOAD', '/home/a2eefcc9/73ed6e063f.nxcli.net/html/system/storage/download/');
define('DIR_LOGS', '/home/a2eefcc9/73ed6e063f.nxcli.net/html/system/storage/logs/');
define('DIR_MODIFICATION', '/home/a2eefcc9/73ed6e063f.nxcli.net/html/system/storage/modification/');
define('DIR_UPLOAD', '/home/a2eefcc9/73ed6e063f.nxcli.net/html/system/storage/upload/');
define('DIR_CATALOG', '/home/a2eefcc9/73ed6e063f.nxcli.net/html/catalog/');

Re: Transferring Site to New Host

Posted: Fri Mar 18, 2022 3:17 am
by straightlight
Using a sub-domain. More configuration from .htaccess or from your host console might be needed for this.

Re: Transferring Site to New Host

Posted: Fri Mar 18, 2022 5:55 am
by xxvirusxx
PHP 8.0?

SOLVED Re: Transferring Site to New Host

Posted: Fri Mar 18, 2022 11:04 pm
by kriswaide
Our new hosting provider looked into the directory paths - /chroot/ paths were added and BAM! Fixed, everything functions like normal in testing prior to site move! We are grateful for all the help! THANK YOU!