Hello everyone. This my first time posting, but I'll try and give as much detail as I can.
My companies Magento website is running version 1.7 and they are asking me if I can update it to 1.9.
But the problem is, there has been some custom changes made to the current website by the previous employee (I just started last week) and if I go ahead and update it to 1.9, these custom changes won't be able to work with 1.9 and the whole website will crash.
Our company uses Plesk 12 to manage/host our websites (we have 6 different ones). What I would like to do, is set up a 'staging' domain from which I can duplicate our current website onto that new staging domain. Without knowing what these custom changes were that were made by the previous employee, my plan is to go ahead and update the staging website to Magento 1.9, see what issues have occurred, and then fix these issues so that I can then apply them to our live website so I can upgrade our live site to 1.9 safely.
I've tried a number of things and nothing seems to work. Are any of you able to help me with step-by-step instructions on how to go about achieving this? I am new to Magento and Plesk so I don't know all the hardcore stuff but I am experienced in PHP/MySQL etc so I know how most things work etc.
Any help would be greatly appreciated.
Thanks!
Thank you for your reply.
I have setup the subdomain now and copied the files/database across.
One problem that has just occurred, when I type in the subdomain url (http://staging.tegiwaimports.com), it keeps on redirecting to our live site all the time (http://www.tegiwaimports.com). Is there a solution to stopping the subdomain url directing to the live website?
Thanks
That is because your recently copied over database still has the old URL's in it.
Using phpmyadmin or command line you should access your database and change the following values:
web/unsecure/base_url
web/secure/base_url
These can be found in the core_config_data table.
If you have command line access and you know what your doing with mysql you can use the bellow commands:
update core_config_data set value = 'http://domainname/' where path = 'web/unsecure/base_url';
update core_config_data set value = 'http://domainname/' where path = 'web/secure/base_url';
Hello,
I have updated the database to the new URL but it is still redirecting to the live website. I have tried clearing the cache just in case but still the same. I would have thought that would have done it as well.
Do you know of any other URLs that could be in other tables that could cause this?
Thanks
In order to make your new database changes live you need to empty the var/cache folder in your Magento installation and also clear your browser cache.
Your browser will actually cache the old redirect.
If you don't want to clear your browser cache you can try Chome Incognito mode or Firefox Private Browsing
Thank you for the reply.
I managed to clear the Magento cache and the browser cache and still, it's redirecting :/ I have also tried in private browsing just to be sure.
It must be something in the Plesk settings but I'm not sure how to find what it could be since I am new to Plesk.
Please double check all of the following values in your core_config_data table to make sure there is no lingering old domain.
web/unsecure/base_url web/unsecure/base_link_url web/unsecure/base_skin_url web/unsecure/base_media_url web/unsecure/base_js_url web/secure/base_url web/secure/base_link_url web/secure/base_skin_url web/secure/base_media_url web/secure/base_js_url
Also check to make sure the domain has not been hard coded into your .htaccess file.
You can also upload a text.txt with some generic contents to see if this loads or gets redirected. If it redirects then it is your server as Magento would not redirect such a file to a different URL.
Thank you for your reply.
I have checked the database and there's no lingering URLs.
However, I did try your text.txt suggestion and that does work. There's no redirect.
So there has to be some sort of database issue or some other URL problem going on somewhere in the files. I did check the .htaccess file and it hasn't been hard coded in.
Thanks
Hi, where did you upload the .txt file too?