Hello WP People
I just had a website created in WP. I want to take this website and use it for a second website(domain name).
I am hosting the site at HostGator. I copied the WP code from the original folder inside the public-html folder to the new folder inside the public-html folder.
The second website is coming up great. Heres the problem when I attempt to login at the second website it takes me to the original website
Here what I mean
secondwebsite.com/wp-admin.php brings up the admin login. i login and then the URL automatically changes to originalwebsite.com/wp-admin
i can get into the cpanel file manager to edit the files in the secondwebsite folder.
i am pretty sure there is one line of code that i need to change from originalwebsite.com to secondwebsite.com
thanks in advance.
i just wrote a huge summary and left the computer for more than a hour and it all got erased when i had to re-login....grrrrrrrr
heres the two sites
heres the short version
i did the change to the config file. i added the two lines of code for the url.
when i logged into the bioforce wp admin it asked to do a database update.
the bioforce site is missing a bunch of pages..weird
add this to your wp-config.php file:
obviosuly using the new path for your website. Should do.
@MagoryNET read carefully, his problem is he cannot access the admin panel ;). To safe dirty work with phpMyAdmin, the fastest way is set it up in wp-config.php as I postedd (overriding DB settings by that). After, you can apply changes to DB and remove the lines.
You also need to duplicate the db same as files, not sure if you already did?
I can try to look into your problem but need additional budget.
If you are using same database, the solution is already given by Andrzej! However, if you are going to use separate database, you need to take some trouble, as I guess you can't login to go to wp-admin/options-general.php as said by MagoryNET!
You need to go to phpMyAdmin and update the 'home' and 'site_url' field to new path in *options table after you have copied the source database.
You also have to update the guid in *posts table as the URLs will be prefixed with previous URL.