Answers.Body: <p>First of all, you should really customize CiviCRM by developing extensions. There is a developer guide that will explain you how this is done: <a href="https://docs.civicrm.org/dev/en/latest/" rel="nofollow noreferrer">https://docs.civicrm.org/dev/en/latest/</a></p>
  
  <p>If you do want to override anyway, you should first of all navigate to Administer>System Settings>Directories to provide the path to the PHP files, have you done this? If you have it should work but I would still recommend to take the extensions route as this is by far the most used and supported route.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-05-22T07:44:06.430Z
Answers.Text: Yes , I have already set directories path of php files and also already override some civicrm core files like /custom_code/CRM/Admin/Form/Setting/Mapping.php file and it is override successfully . but /custom_code/CRM/Utils/ReCAPTCHA.php file is not overriding.
Answers.UserDisplayName: jagjeet
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-05-22T10:09:47.047Z
Answers.Text: I understand. I repeat my recommendation to write an extension rather than overriding core files.
Answers.UserDisplayName: ErikH - CiviCooP
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-05-22T11:23:44.250Z
Answers.Text: Okay. I am reading https://docs.civicrm.org/dev/en/latest/.
Answers.UserDisplayName: jagjeet
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-05-22T14:06:00.397Z
Answers.Text: Cool, do ask questions if you need any help, either here or on the dev channel on Mattermost?
Answers.UserDisplayName: ErikH - CiviCooP
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-05-21T12:51:52.503Z
Answers.LastActivityDate: 2019-05-21T12:51:52.503Z
Answers.UserDisplayName: ErikH - CiviCooP
Body: <p>Override Civicrm Utils file 
  /sites/all/modules/civicrm/CRM/Utils/ReCAPTCHA.php 
  to 
  /custom_code/CRM/Utils/ReCAPTCHA.php . 
  it is not working. I have cleared the drupal cache and also cleared /civicrm/admin/setting/updateConfigBackend?reset=1 cache. What thing is missing please guide me how can override civicrm files?</p>
  
Tags: <drupal><recaptcha>
Title: How can i override Civicrm /CRM/Utils Files?
ThreadText: # How can i override Civicrm /CRM/Utils Files?
  
  (Asked by: username_0 on 2019-05-21)
  
  Override Civicrm Utils file
  /sites/all/modules/civicrm/CRM/Utils/ReCAPTCHA.php
  to
  /custom\_code/CRM/Utils/ReCAPTCHA.php .
  it is not working. I have cleared the drupal cache and also cleared /civicrm/admin/setting/updateConfigBackend?reset=1 cache. What thing is missing please guide me how can override civicrm files?
  
  **Tags:** drupal, recaptcha
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2019-05-21. Score: 1
  
  First of all, you should really customize CiviCRM by developing extensions. There is a developer guide that will explain you how this is done: <https://docs.civicrm.org/dev/en/latest/>
  
  If you do want to override anyway, you should first of all navigate to Administer>System Settings>Directories to provide the path to the PHP files, have you done this? If you have it should work but I would still recommend to take the extensions route as this is by far the most used and supported route.
  
  > **Comments:**
  > **username_0**: Yes , I have already set directories path of php files and also already override some civicrm core files like /custom_code/CRM/Admin/Form/Setting/Mapping.php file and it is override successfully . but /custom_code/CRM/Utils/ReCAPTCHA.php file is not overriding.  
  > **username_1**: I understand. I repeat my recommendation to write an extension rather than overriding core files.  
  > **username_0**: Okay. I am reading https://docs.civicrm.org/dev/en/latest/.  
  > **username_1**: Cool, do ask questions if you need any help, either here or on the dev channel on Mattermost?  
  
  ---
  
  