Answers.Body: <p>I just found and fixed the same problem. There are two possible fixes to this problem, only one of which is available to you immediately.  As per usual, Chris nails it.</p>
  
  <p>In your <code>civicrm.settings.php</code> file, there's a line <code>$civicrm_root = /path/to/civicrm</code>.  If you have a symlink in that path, then the <code>[civicrm.root]</code> is miscalculated.  So the easy fix is to fix your <code>$civicrm_root</code> to the non-symlink path to the file.</p>
  
  <p>The longer-term fix is this line:
  <code>CRM/Core/Resources.php:          'wysisygScriptLocation' =&gt; Civi::paths()-&gt;getUrl("[civicrm.root]/js/wysiwyg/crm.ckeditor.js"),</code></p>
  
  <p>This shouldn't call <code>civicrm.root</code>, it should use the resource URL.  I'll try and post a bug report (and maybe even a fix!) if I find a moment - but first, like you, I need to get my mailing out :)</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-07-20T13:44:59.427Z
Answers.Text: I've come across this today and it took me a very long time to find this post. Thanks Jon G
Answers.UserDisplayName: Jon-man
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-07-20T14:01:36.750Z
Answers.Text: Hey Jon G did you ever get a chance to investigate this one and find out why Civi is miscalculating the `[civicrm.root]` token?
Answers.UserDisplayName: Coleman
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-07-20T15:09:32.173Z
Answers.Text: @coleman I didn't.  I feel like there's this whole area of symlinks in Civi config that require some in-depth knowledge.  The Civi/WordPress experts have that knowledge, but I don't!
Answers.UserDisplayName: Jon G - Megaphone Tech
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-12T06:32:22.267Z
Answers.LastActivityDate: 2017-02-12T06:32:22.267Z
Answers.UserDisplayName: Jon G - Megaphone Tech
Body: <p>At some point ckeditor broke for us.  Developer tools show me it is not loading because :</p>
  
  <pre><code>Common.js?ol145e:249 GET https://home/NAMEREMOVED/www/www/sites/all/modules/civicrm/js/wysiwyg/crm.ckeditor.js net::ERR_NAME_NOT_RESOLVED
  </code></pre>
  
  <p>I can't seem to find the appropriate place to fix this.  As I usually don't poke around the guts.</p>
  
  <p>Everything else seems to be loading appropriately from the domain instead, i.e. <a href="https://domain.name/sites/all/modules/etc" rel="nofollow noreferrer">https://domain.name/sites/all/modules/etc</a>.....</p>
  
  <p>Any thoughts?  We haven't migrated the server just updated it.  </p>
  
  <p>CiviCRM version 4.7.16 is up-to-date.  We are on Drupal 7.54?  I have shell access and can edit files.</p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-02-08T00:49:00.433Z
Comments.Text: Do other components of your site live inside www/www? I've never seen that before. It would be worth checking.
Comments.UserDisplayName: Christia
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-02-08T01:28:28.780Z
Comments.Text: It sounds like CiviCRM is miscalculating the path to your `crm.ckeditor.js`. You might be able to trace this down - could be a symlink or misconfig in CiviCRM (check the BASEURL setting in `civicrm.settings.php`, and resource URL in admin UI). If all else fails, you can catch that incorrect URL and redirect to the correct one from your webserver or using Drupal's [Redirect module](https://www.drupal.org/project/redirect).
Comments.UserDisplayName: Chris Burgess
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-02-12T06:16:25.473Z
Comments.Text: I've got the same problem - my Resource URL directory was wrong but I just fixed it, but even after removing templates_c and `drush cc all` the ckeditor.js file has the wrong URL...will report if I get an update. 4.7.15 here.
Comments.UserDisplayName: Jon G - Megaphone Tech
Tags: <drupal><ckeditor>
Title: Directory not replaced with site name?
ThreadText: # Directory not replaced with site name?
  
  (Asked by: username_0 on 2017-02-08)
  
  At some point ckeditor broke for us. Developer tools show me it is not loading because :
  
  ```
  Common.js?ol145e:249 GET https://home/NAMEREMOVED/www/www/sites/all/modules/civicrm/js/wysiwyg/crm.ckeditor.js net::ERR_NAME_NOT_RESOLVED
  
  ```
  
  I can't seem to find the appropriate place to fix this. As I usually don't poke around the guts.
  
  Everything else seems to be loading appropriately from the domain instead, i.e. <https://domain.name/sites/all/modules/etc>.....
  
  Any thoughts? We haven't migrated the server just updated it.
  
  CiviCRM version 4.7.16 is up-to-date. We are on Drupal 7.54? I have shell access and can edit files.
  
  **Tags:** drupal, ckeditor
  
  > **Comments:**
  > **username_1**: Do other components of your site live inside www/www? I've never seen that before. It would be worth checking.  
  > **username_2**: It sounds like CiviCRM is miscalculating the path to your `crm.ckeditor.js`. You might be able to trace this down - could be a symlink or misconfig in CiviCRM (check the BASEURL setting in `civicrm.settings.php`, and resource URL in admin UI). If all else fails, you can catch that incorrect URL and redirect to the correct one from your webserver or using Drupal's [Redirect module](https://www.drupal.org/project/redirect).  
  > **username_3**: I've got the same problem - my Resource URL directory was wrong but I just fixed it, but even after removing templates_c and `drush cc all` the ckeditor.js file has the wrong URL...will report if I get an update. 4.7.15 here.  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_3 on 2017-02-12. Score: 6
  
  I just found and fixed the same problem. There are two possible fixes to this problem, only one of which is available to you immediately. As per usual, username_2 nails it.
  
  In your `civicrm.settings.php` file, there's a line `$civicrm_root = /path/to/civicrm`. If you have a symlink in that path, then the `[civicrm.root]` is miscalculated. So the easy fix is to fix your `$civicrm_root` to the non-symlink path to the file.
  
  The longer-term fix is this line:
  `CRM/Core/Resources.php: 'wysisygScriptLocation' => Civi::paths()->getUrl("[civicrm.root]/js/wysiwyg/crm.ckeditor.js"),`
  
  This shouldn't call `civicrm.root`, it should use the resource URL. I'll try and post a bug report (and maybe even a fix!) if I find a moment - but first, like you, I need to get my mailing out :)
  
  > **Comments:**
  > **username_4**: I've come across this today and it took me a very long time to find this post. Thanks Jon G  
  > **username_5**: Hey Jon G did you ever get a chance to investigate this one and find out why Civi is miscalculating the `[civicrm.root]` token?  
  > **username_3**: @username_5 I didn't.  I feel like there's this whole area of symlinks in Civi config that require some in-depth knowledge.  The Civi/WordPress experts have that knowledge, but I don't!  
  
  ---
  
  