Unexpected CiviCRM behavior after clone
-
wrote on Jul 13, 2023, 4:38 PM last edited by
I ran into an issue a bit ago similar to this. When I cloned the app it copied the database details from the old WordPress app into the cloned version. You can open wp-config.php on both apps and see if they match. If they match, then that would more than likely be the problem.
-
wrote on Jul 13, 2023, 9:33 PM last edited by
Thank you.
Each wp-config.php is unique.
To elaborate, only the CiviCRM data was the same. Creating posts did not carry over across WordPress instances.
-
wrote on Jul 13, 2023, 9:40 PM last edited by
Update: The civicrm.settings.php files are the same across both WordPress instances.
I guess I would need to completely re-install CiviCRM to have a unique environment.
-
@superhua this is most likely because CiviCRM in clone is using the same database as the previous installation. How does one configure CiviCRM ? Do you have to give it database information ? In general, it's not possible for the clone to access the previous app's database.
Another aspect could be that maybe CiviCRM is using an API or external service? In that case too, contacts will appear in both places.
-
@superhua I had this kind of problem after a wordpress clone with CiviCRM.
I had trouble understanding.
-
@superhua this is most likely because CiviCRM in clone is using the same database as the previous installation. How does one configure CiviCRM ? Do you have to give it database information ? In general, it's not possible for the clone to access the previous app's database.
Another aspect could be that maybe CiviCRM is using an API or external service? In that case too, contacts will appear in both places.
-
@girish I installed CiviCRM by uploading the file to the plugin page under the WordPress dashboard.
From there, it auto configured itself. I did not give it database information.
-
@superhua Is https://docs.civicrm.org/installation/en/latest/wordpress/ the setup/download you are talking about? Just testing it out myself.
Edit: OK, indeed, when installing CiviCRM, it's reading the raw DB credentials from wordpress:
And it's stored raw in the above civicrm.settings.php file: