Zen Cart Logo
Forums / Search Engines / Domain points to change

Domain points to change

Views: 49

Results 1 to 7 of 7
22 Aug 2017, 4:01 PM
#1
gunni avatar

gunni

Zen Follower

Join Date:
Aug 2010
Location:
Israel
Posts:
287
Plugin Contributions:
0

Domain points to change

Hi,
I have a domain that points to a root directory and I want to change it to points to a subdirectory.
The reason is that I want to upgrade (rebuild) it on a different directory and when I see that all is
working well, I want to change the 'points to' to the new directory.
The 'points to' is dones in my hosting company panel. I only need to put the /directory and it will
redirects it and no one will know.
User/visitor would not see the change. The top domain will still be https://www.mysite.com

The question is about search engines.
I want to be sure that it will not affect search engines results and they will see the site as the users -
https://www.mysite.com

22 Aug 2017, 5:04 PM
#2
mc12345678 avatar

mc12345678

Totally Zenned

Join Date:
Jul 2012
Posts:
16,908
Plugin Contributions:
2

Re: Domain points to change

With all of that in place, the SEs will see the same thing that the "public" sees.

Whether for you or others reading. A recommended process to accomplish this and maintain relatively uninterrupted operation is to first copy the files to this sub-directory. Include anything/everything that is to remain operational from your site such as the htaccess file, subfolders, etc...
Modify the new includes/configure.php (remember to alter the permissions to 644 before saving changes) and admin/includes/configure.php to reflect in this case (for now) that the site files and uri are in a sub-folder. (DIR_FS_ and DIR_WS_)

Attempt to access the site from the new sub-directory and verify basic operations work.
When satisfied, modify the configure.php files from above to remove the sub-directory modifications made to the constant(s) beginning with DIR_WS_
Make the change that your host does to redirect traffic to this sub-directory such that users will still see the site without a sub-directory.

Make a minor modification to one of the files such that an additional character or symbol appears on a specific page (not a database related file, but an actual file and do so through ftp rather than the admin, though suggest modifying one of the define pages found in: includes/languages/YOUR_LANGUAGE/html_includes/YOUR_TEMPLATE. This way you can verify via the admin that the admin is accessing the correct location).

While the change should occur rapidly, verify (after clearing cache/cookies) that when accessing the site, that the minor modification is visible. There may still be other servers with the host that need to propagate the change "internally", but you should now be able to initiate a rebuild/upgrade in yet another parallel sub-folder to be referenced possibly with a sub-domain.

22 Aug 2017, 5:32 PM
#3
mprough avatar

mprough

Totally Zenned

Join Date:
Nov 2007
Location:
Woodbine, Georgia, United States
Posts:
4,284
Plugin Contributions:
37

Re: Domain points to change

With regard to rank, you will want to properly redirect the old page locations with a 301, permanent redirect. Then make certain to update your search engines sitemap. It will take the search engines some time to pick up on the new locations and in the meantime the pages are redirected for your users. There WILL be some rank loss due early on whilst they update the index and SOME loss will remain after due to inevitable link decay. However, if this is the right thing to do for your users, then make it so =)

~Melanie

22 Aug 2017, 5:37 PM
#4
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: Domain points to change

gunni,

CAUTION.

What you're aiming to do still requires a temporary database "copy". And then when going "live" need to change the DB_* settings in the configure.php files, followed by a re-run of zc_install to update the db schema, plus all your admin config changes and plugin installs. What you've written appears to be an attempt to fast-track things, but in the end will end up in loss of data.

It is better to follow the steps explained here: http://www.zen-cart.com/entry.php?3-How-do-I-rebuild-my-site-on-the-new-version-instead-of-upgrading ... If you want to do that in a temporary directory + database on the same server, that's fine. And if you want to re-point the domain to the other directory later, that's fine, but you must still do the re-copy-the-database-and-use-zc_install-to-upgrade-it-and-then-configure-all-admin-settings-and-plugins step or you will lose data.

22 Aug 2017, 5:42 PM
#5
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: Domain points to change

mprough:

With regard to rank, you will want to properly redirect the old page locations with a 301, permanent redirect. Then make certain to update your search engines sitemap. It will take the search engines some time to pick up on the new locations and in the meantime the pages are redirected for your users. There WILL be some rank loss due early on whilst they update the index and SOME loss will remain after due to inevitable link decay. However, if this is the right thing to do for your users, then make it so =)

~Melanie
Yes and no.

In the case of redirecting a domain from one storage location to another, when the resulting generated URLs are the same, there's no difference to visitors or search engines or indexed page data, and therefore no SEO impact.

Now, if the resulting generated URLs are different, then yes, there are a lot of considerations, plus redirect rules to implement, etc.

22 Aug 2017, 6:03 PM
#6
mc12345678 avatar

mc12345678

Totally Zenned

Join Date:
Jul 2012
Posts:
16,908
Plugin Contributions:
2

Re: Domain points to change

DrByte:

gunni,

CAUTION.

What you're aiming to do still requires a temporary database "copy". And then when going "live" need to change the DB_* settings in the configure.php files, followed by a re-run of zc_install to update the db schema, plus all your admin config changes and plugin installs. What you've written appears to be an attempt to fast-track things, but in the end will end up in loss of data.

It is better to follow the steps explained here: http://www.zen-cart.com/entry.php?3-How-do-I-rebuild-my-site-on-the-new-version-instead-of-upgrading ... If you want to do that in a temporary directory + database on the same server, that's fine. And if you want to re-point the domain to the other directory later, that's fine, but you must still do the re-copy-the-database-and-use-zc_install-to-upgrade-it-and-then-configure-all-admin-settings-and-plugins step or you will lose data.

My understanding of the request though never specifically asked, was that an internal sub-directory was where gunni probably had wanted to have the site installed in order to support using other internal directories for other reasons (ie. To support an upgrade). While this sub-directory may already exist with the upgraded site already present, I'm not so sure that it is as much a "short cut" as a slightly modified means to place the site online.

open mouth insert foot
Okay, so I just reread the entirety of the post... I was tainted by content of a previous similar post that eluded to continuing operation of the existing site in a sub-directory such that the new development site could be initiated. The request (which really is quite clearly stated when read) is something of the other way around...

Personally I'd rather rename a folder and do the database upgrade than wonder if the Internet service was properly guiding customers to the correct version of the site and by version mostly meaning at that point the correct database. Ideally/ultimately at the point of switching the path, the oldsite should be put into maintenance mode so that any initial accidental arrivers will not cause modification of the database in any significant amount.

Ah well, I answered a different question at least regarding the details. If the existing database has been used to upgrade (ie. Imported/referenced and upgraded as part of making the old site being unreachable), then the uris will be the same and in that case I would still say no loss in rankings as a result of the uri information.

22 Aug 2017, 6:37 PM
#7
gunni avatar

gunni

Zen Follower

Join Date:
Aug 2010
Location:
Israel
Posts:
287
Plugin Contributions:
0

Re: Domain points to change

Thanks Zenners,
I only wanted a "yes" :wink:
But seriously, I'll read it carefully again (&again(&again))...