• I’d like to use and then tweak a theme I’m considering by having it pull from the database of another one of my sites. The idea is that if I like what I can do with the content from my other site with this new theme, then I’ll install the theme to the other site and do the same tweaks.

    Do I have to duplicate the database from the other site – and if so how do you do this through myphpAdmin – or can this be done?

    All help appreciated,

    Michael
    Host of The Psych Files podcast
    https://www.psychfilespodcast.com

Viewing 12 replies - 1 through 12 (of 12 total)
  • you can just have the wp-config file have the database info, only problem is the database also holds your path, i think the best way for you is to test locally,

    zip the site files, download a export of your database using phpmyadmin and, get m/l/w-amp setup locally and test the themes locally on your machine

    Thread Starter mbritt

    (@mbritt)

    Follow-up:

    Or how about this: what if I backup the database from my main site, then create a new database in myphpAdmin and then import the backup into this new database. Then I point the other site to use this new database and then I can tweak as much as I want without touching my main site.

    Sounds like it’ll work. Is this the best way to go about this?

    Thanks.

    Michael

    yeah that would work, but why go though the trouble when you can set up a local server in minutes, and testing locally is much faster, no upload waits, and you can back up and make mistakes as much as you want without effecting the server

    You can just make your test domain/site block google first and then import your current site . All posts /categories comments etc . I have done it to test new themes.

    Go to your main site Manage>export>download export file.

    Then to your test site and import it.

    But as i said make sure to go to settings>privacy and make your blog private from search engines first!

    And i forgot , you can also use this plugin

    https://www.prelovac.com/vladimir/wordpress-plugins/theme-test-drive

    on your main site.

    But i have a test site anyway.

    yeah you can use the export function, but not always the best way to go, if you have plugins that use databases, or you have custom fields, sometimes leads to errors,

    thats why i say use locally, you can use https://www.wampserver.com/ for windows
    and mamp on apple https://www.mamp.info/en/index.php

    Thread Starter mbritt

    (@mbritt)

    I tried creating a new database and importing the backed up database from my main site, but when I go to the new site it re-directs to the main site. Why would that happen?

    I may try the idea of running it on a local server. That make sense. But if anyone knows the answer to the above question that would be great. And thanks for the info about blocking this from Google – I’d want to do that for sure.

    Michael

    right thats because, in teh wp-options table, you have to change the root links

    this is in your database:
    i have done this, before there is two fields in the wp-options table
    first one is the “siteurl” option and than “home” option
    change those two to the new link

    Thread Starter mbritt

    (@mbritt)

    I decided to go with using MAMP. I followed the directions on how to install it on my Mac and I got MAMP to recognize a brand new wordpress blog. I have a backup of my main site blog that I downloaded a couple days ago, so I created a new database and imported the backup. That all went fine, but what I can’t figure out is how to get MAMP to use this new database. I changed the config file to what I thought was correct, but all I get when I try to connect (locally) is a blank screen. Any suggestions?

    Thanks!

    ohh yeah sorry for the late reply, in mamp change the settings to default apache mysql ports, which are 80 apache and 3306 for mysql

    than in phpmyadmin of mamp, the user that u are using in the config file, put his permissions all, and have localhost be its database

    in privileges you have the users and their hosts, for the user “for example wordpress” put “localhost” as its host and global privileges “all”

    this is the link that you should have for the privileges menu
    https://localhost:80/MAMP/frame.php?src=%2FphpMyAdmin%2F%3Flang%3Den-iso-8859-1&language=English

    i love mamp myself too use it on all of my macs

    Hi Vachi,

    I took an existing blog I am using and exported the database to test a new theme locally and your instructions and it worked great.

    When I imported the database to use locally, It did not import the plug-ins I have installed.

    Can I get those to work locally as well?

    thanks

    Hi Bpike,

    Reading this just now because I did a search for something else.
    The external database doe snot contain your plugins and themes. If yo did a fresh WP setup locally yo still have to copy the files/directory’s in wp-content into your local/pc WordPress directory.

    And then check if the plugins are activated.

Viewing 12 replies - 1 through 12 (of 12 total)
  • The topic ‘Test a theme by having two sites use the same database’ is closed to new replies.