Prestashop migration procedure - migration

I have a client who wants to move their hosting provider and we have successfully cloned exact copy of original server to the new hosting provider's server. We want to use different domain name staging.copiedsite.com to creating staging environment to check everything works fine, then we want to flicker it back to original DNS (www.actualsite.com). My question is, how do you configure the site to work with staging domain name? I am going to basically find all database record that says "www.actualsite.com" and replace it with "staging.copiedsite.com". Is that all it needs? Is there any configuration text file that I need to edit? Thanks.

You shall change the domain in BackOffice > Preferences > SEO & URLs. This will update configuration in database and your .htaccess file (For some obscure reason you might have to save this page two times so that the .htaccess file is overwritten).
Also some CMS pages and modules can use absolute URLs so changing all those values by querying the database is a good idea.
Basically that's all you need.

Related

Wordpress Database & WP Migrate

I built a WordPress website in localhost MAMP. Upon completing the site, I wanted to upload it to the actual hosting site using FTP. I uploaded all the content but DB. I used a WordPress plugin called 'WP Migrate' to export the database. Then I uploaded exported file to phpMyAdmin.
But the site did not work after uploading onto my site using FTP. I then begin to work again locally, using my local host. There is a feature to find & replace DB values in 'WP Migrate'. I replaced existing local site name with actual web site name. This stopped working my local website also.
I am not trying to figure the live site, but figure the local host site right now, that way I can perform a transfer. I believe it has to do with the DB somehow but not sure where or how to edit it.
Basically it is the same issue that this person is having as well, but the question wasn't answered: https://wordpress.org/support/topic/undo-find-replace/
Nathan Rojas
If it's after you updated your site name, you can easily change it back by logging into the myPhpAdmin of your local site and choosing the MySQL database you are using. under the wp_options table, you'll see a field called siteurl and home. Update those fields to what you had prior and it'll come back. ;)

prestashop not changing base url

I have an installation of prestashop 1.6 on a domain www.mydomain.com and a virtualhost on a server for redirecting to the prestashop/public_html folder. This is my main website working perfect.
Now i would like to clone the installation in another folder prestashop/clone_html and i created an alias on the virtualhost from www.mydomain.com/clone to prestashop/clone_html
Now if i access the clone website the frontend is not working, i get a 404 error and all the links are pointing on the main domain
I tried to change settings.inc.php change the base URI on the database and delete both .htaccess and cache but the links are never changing.
I think maybe the problem is coming from multilanguage redirect?
Do you have any idea what i should try to change?
Thanks
That is a good one! If you want to change the URL of the store and you have already migrated the contents (so no access to the admin is possible or you don´t want to bother), you may do the change directly at the PS table where this information is kept. The name of the table is <prefix>shop_url. Once you access it, the content is self explanatory. You have to play with domain or domain_ssl and then with physical_uri.
Also, using a subdomain as has been suggested in a comment may be a good idea. Depending on your hosting, you may be able to define a subdomain and make it point to a subdirectory. This keeps the physical_uri to / and may avoid other potential problems.

Prestashop Error 404 at moving to server

At moving from local to a server my prestashop web, appears all the text (I think it connects correctly to the database), but it doesn´t visualizing any images,CSS,etc... I´ve modified config/settings.inc.php file
and modified PS_SHOP_DOMAIN, PS_SHOP_DOMAIN_SSL and SHOP_URL from the database and also deleted the .htaccess file.
Thanks!
The same is with the backoffice:
you can do it by two ways:
navigate into backoffice to SEO&URL link, set correct values for Shop domain & SSL domain & Base URI fields. Save & update page.
or
in DB find tables:
ps_configuration, set correct values for PS_SHOP_DOMAIN and PS_SHOP_DOMAIN_SSL
ps_shop_url set correct values for domain, domain_ssl, physical_uri
Some Prestashop installs, sometimes have SSL ON (don't know why).
If you are installing it on a server with no SSL certificate, all images and styles will not be loaded and the PHP scripts display barebones HTML pages.
To solve this:
In your Prestashop directory, delete all install directories and files to get the platform running.
Type your admin URL, example: http://yourstore.me/psadmin, log in with a registered valid admin user, and go to to PREFERENCES->CONFIGURATION and turn all SSL parameters to off.

Simulate dynamically subdomains with .htaccess with a different database but same code base in Drupal

Sorry about my english level.
I researched so much, and i found that can i use ".htaccess" to get redirection to subdomain folder and this is OK.
In Drupal i need to create a folder for each subdomain in "/sites/sub.example.com/" and copy "default.settings.php" from default folder "/sites/default/default.setting.php" and rename it to "settings.php", after that, enable "$databases" variable in the same file, when it's done, i need to add a wildcard and modify "hosts" file.
Well, i should "automate" all this, but i don't know if it's is more hard because it's important hold the server safety with writing permissions or try another way, someone could advise me.
Im working on OSX and Drupal 7.x (recent release)
Thank you very much.
For each site that you want to use separate database, create own sites/ directory with settings.php. For example, if you want to have one database for example.com, another one for sub1.example.com and third one for sub2.example.com, all using same code base, setup your files like this:
sites/example.com/settings.php
sites/sub1.example.com/settings.php
sites/sub2.example.com/settings.php
each settings.php using different database credentials.
Read more here - https://drupal.org/documentation/install/multi-site
Also, if you want to automate this and if there is supposed to be bigger number of sites to be managed, consider deploying aegir - http://www.aegirproject.org.
I hope I understood your question correctly.

How to move a single DotNetNuke portal to a new server?

I've got a DotNetNuke system (v 5.6) that's hosting several different portals, and I'd like to move one of them to another hosting provider. What's the easiest way to do this?
Every web site I find that claims to explain how to move a DotNetNuke site essentially says "Copy the entire database over to the new system." That's great if you've only got one portal in the database, but I've got a dozen of them. I only want to move one portal, not all of them.
Exporting the site to a .template is another popular suggestion. This exports the structure of the site (all the tab definitions, for example), but it doesn't include any of the actual HTML content. As such, that's essentially worthless.
There must be a reasonable way to do this short of trying to strip one individual portals data out of every single DNN table. Right?
When you export a site template, you can include the content of the site, as well (for the modules that support portability, which includes the standard HTML module). This is how the default site template has all of its content. When you do this, there will be a .template.resources file that you'll need, as well as the .template file.
The other option is to do a full backup and restore, and then remove the other sites once you've restored. If you have significant content in a module that doesn't support portability, I think this will be your best bet.
FYI, I did find a solution from someone over on the DotNetNuke forums.
Create a 2nd version of that install, then delete all the other
portals. Move the install with the one portal. We've done this several
times with installs with lots of portals and it works just fine. Yeah
there's still some noise left in the db, but it's a quick and
effective way of doing things.
Edit note that this will give you an install with 1 portal. You can't detach a portal from one install and reattach it to an existing
install (well, you can, but basically you have to export the portal as
a template and that isn't 100%)
This is the approach I took, and sure enough, it works.
In a nutshell:
Mirror the files for the web site to another server.
Mirror the DNN database to another server.
Log in a Host on the new setup and delete all the portals but the one you want to migrate.
Delete any module definitions that are not in use by the remaining portal.
Open up your favorite SQL tool and delete any entries in the Users and UserProfile tables that no longer have a matching row in the UserPortals table. DNN does not remove these by default, which is frustrating.
Hop in to Windows Explorer and delete all of the Portal folders you no longer need (ie: /Portal/1, /Portal/2, etc.)
Back up the database using Enterprise Manager to create a .bak file
Make a .zip of the entire DNN installation folder.
You now have a .bak that contains the database and a .zip that contains the files. Send those off to the new hosting company, and you should be all set. Just make sure to update your web.config to set the connection string properly to point to the new database server at the new hosting company.
It's just that easy. ;)