Answers.Body: <p>Had to change the path name in civicrm.settings.php from:</p>
  
  <pre><code>G:\XAMPP_2018\htdocs\crm4
  </code></pre>
  
  <p>To</p>
  
  <pre><code>C:\Core\XAMPP_2018\htdocs\crm4\
  </code></pre>
  
  <p>This is around LINE 180:</p>
  
  <p>Code looks like this:</p>
  
  <p>$civicrm_root = 'G:/August25/XAMPP_2018/htdocs/crm4/sites/all/modules/civicrm';
  if (!defined('CIVICRM_TEMPLATE_COMPILEDIR')) {
    define( 'CIVICRM_TEMPLATE_COMPILEDIR', 'G:/August25/XAMPP_2018/htdocs/crm4\sites\default\files\civicrm\templates_c\');
  }</p>
  
  <p>But the slashes also have to be forward like this "/", I searched from Windows path, that's why I couldn't find the code using find and replace!</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-08-25T11:30:56.080Z
Answers.LastActivityDate: 2018-08-25T11:30:56.080Z
Answers.UserDisplayName: Bruno  Vincent
Body: <p>I have xampp portable installed on Windows 10.</p>
  
  <p>I run about a dozen Drupal, Wordpress and other CMS on there. I can move the whole stack to different drives and machines and it all works perfectly, only one that can't work is D7/CIVICrm install.</p>
  
  <p>When I move it to another directory I get this error:</p>
  
  <pre><code>fatal error: Cannot redeclare class CRM_Core_ClassLoader in C:\Core\XAMPP_2018\htdocs\crm4\sites\all\modules\civicrm\CRM\Core\ClassLoader.php on line 36
  </code></pre>
  
  <p>Any idea how to make this work?</p>
  
  <p>The files are absolutely identical from source to location, copy and paste whole Xampp portable folder...</p>
  
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-08-24T06:03:09.733Z
Comments.Text: Try install a fresh copy first and then try to restore the backup of CiviCRM Database that should work
Comments.UserDisplayName: Ramesh - ARTECH Consultancy
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-08-24T10:38:27.527Z
Comments.Text: That's what I'm doing, now working
Comments.UserDisplayName: Bruno  Vincent
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-08-24T12:13:45.633Z
Comments.Text: Have you tried - https://civicrm.stackexchange.com/questions/3978/cannot-redeclare-class-crm-core-classloader-in-backup-site ?
Comments.UserDisplayName: Ramesh - ARTECH Consultancy
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-08-25T01:46:36.293Z
Comments.Text: Nope , NONE of that works, I think I might just drop CIVI CRM, I need a portable solution, been a week now...;(
Comments.UserDisplayName: Bruno  Vincent
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-08-25T02:15:17.923Z
Comments.Text: Ok, I see something wrong here...the path of the error is C:\Core\XAMPP_2018\htdocs\crm4\ but the new destination path is: G:\XAMPP_2018\htdocs  , so where can I change that setting? I take some kind of settings.php , config file or in the database with PHPmy admin?
Comments.UserDisplayName: Bruno  Vincent
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-08-25T06:59:10.833Z
Comments.Text: you should see civicrm_setting file in sites/default/ if you need more help please let me know
Comments.UserDisplayName: Ramesh - ARTECH Consultancy
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-08-25T07:24:18.633Z
Comments.Text: I did a find and replace, I couldn't find any instances of C:\Core\XAMPP_2018\htdocs\crm4\  in any files in destination folder, only log files, I'm at a loss!
Comments.UserDisplayName: Bruno  Vincent
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-08-25T07:33:35.430Z
Comments.Text: Let us [continue this discussion in chat](https://chat.stackexchange.com/rooms/82217/discussion-between-artech-consultancy-and-bruno-vincent).
Comments.UserDisplayName: Ramesh - ARTECH Consultancy
Tags: <export>
Title: Getting errors when moving D7/CiviCRM install form localhost xampp portable to another location
ThreadText: # Getting errors when moving D7/CiviCRM install form localhost xampp portable to another location
  
  (Asked by: username_0 on 2018-08-24)
  
  I have xampp portable installed on Windows 10.
  I run about a dozen Drupal, Wordpress and other CMS on there. I can move the whole stack to different drives and machines and it all works perfectly, only one that can't work is D7/CIVICrm install.
  When I move it to another directory I get this error:
  fatal error: Cannot redeclare class CRM_Core_ClassLoader in C:\Core\XAMPP_2018\htdocs\crm4\sites\all\modules\civicrm\CRM\Core\ClassLoader.php on line 36
  
  Any idea how to make this work?
  The files are absolutely identical from source to location, copy and paste whole Xampp portable folder...
  
  **Tags:** export
  
  > **Comments:**
  > **username_1**: Try install a fresh copy first and then try to restore the backup of CiviCRM Database that should work  
  > **username_0**: That's what I'm doing, now working  
  > **username_1**: Have you tried - https://civicrm.stackexchange.com/questions/3978/cannot-redeclare-class-crm-core-classloader-in-backup-site ?  
  > **username_0**: Nope , NONE of that works, I think I might just drop CIVI CRM, I need a portable solution, been a week now...;(  
  > **username_0**: Ok, I see something wrong here...the path of the error is C:\Core\XAMPP_2018\htdocs\crm4\ but the new destination path is: G:\XAMPP_2018\htdocs  , so where can I change that setting? I take some kind of settings.php , config file or in the database with PHPmy admin?  
  > **username_1**: you should see civicrm_setting file in sites/default/ if you need more help please let me know  
  > **username_0**: I did a find and replace, I couldn't find any instances of C:\Core\XAMPP_2018\htdocs\crm4\  in any files in destination folder, only log files, I'm at a loss!  
  > **username_1**: Let us [continue this discussion in chat](https://chat.stackexchange.com/rooms/82217/discussion-between-artech-consultancy-and-bruno-vincent).  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_0 on 2018-08-25. Score: 1
  
  Had to change the path name in civicrm.settings.php from:
  G:\XAMPP_2018\htdocs\crm4
  
  To
  C:\Core\XAMPP_2018\htdocs\crm4\
  
  This is around LINE 180:
  Code looks like this:
  $civicrm_root = 'G:/August25/XAMPP_2018/htdocs/crm4/sites/all/modules/civicrm';
  if (!defined('CIVICRM_TEMPLATE_COMPILEDIR')) {
    define( 'CIVICRM_TEMPLATE_COMPILEDIR', 'G:/August25/XAMPP_2018/htdocs/crm4\sites\default\files\civicrm\templates_c\');
  }
  But the slashes also have to be forward like this "/", I searched from Windows path, that's why I couldn't find the code using find and replace!
  
  
  ---
  
  