Answers.Body: <p>SVGs are fine, but the <code>brokenImagePath</code> needs to be an absolute file path.</p>
  <p>The setting supports <a href="https://craftcms.com/docs/4.x/config/general.html#aliases" rel="nofollow noreferrer">aliases</a>, so if your <code>@webroot</code> alias is properly configured it could be set to</p>
  <pre><code>'brokenImagePath' =&gt; '@webroot/assets/ui/default/image_404.svg',
  </code></pre>
  <p>See <a href="https://craftcms.com/docs/4.x/config/general.html#brokenimagepath" rel="nofollow noreferrer">the official docs on the <code>brokenImagePath</code></a> for more details.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2023-04-25T11:55:07.963Z
Answers.Text: Thanks for the answer, that was it :)
Answers.UserDisplayName: mitrol
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2023-04-25T07:43:58.437Z
Answers.LastActivityDate: 2023-04-25T07:43:58.437Z
Answers.UserDisplayName: Mats Mikkel Rummelhoff
Body: <p>I’ve converted an old site with 15+ years of posts over to Craft from WP. There were a lot of missing images, I’ve handled this with the broken image path setting in the config/general.php.</p>
  <p>However, I’m getting numerous missing image errors in the PHP log and each one is accompanied by the following error:</p>
  <pre><code>yii\base\InvalidConfigException: Invalid broken image path: /assets/ui/default/image_404.svg in /home/customer/www/[ SITE ]/vendor/craftcms/cms/src/controllers/AppController.php:626
  </code></pre>
  <p>That path (/assets/ui/default/image_404.svg) is correct, the image is there.</p>
  <p>I have a couple of ideas:</p>
  <ol>
  <li>It needs to be an absolute path</li>
  <li>Maybe an SVG is no good and it needs to be a PNG/WebP</li>
  </ol>
  <p>Can anyone suggest anything else I can try?</p>
  
Tags: <error-message><image>
Title: Invalid broken image path
ThreadText: # Invalid broken image path
  
  (Asked by: username_0 on 2023-04-24)
  
  I’ve converted an old site with 15+ years of posts over to Craft from WP. There were a lot of missing images, I’ve handled this with the broken image path setting in the config/general.php.
  
  However, I’m getting numerous missing image errors in the PHP log and each one is accompanied by the following error:
  
  ```
  yii\base\InvalidConfigException: Invalid broken image path: /assets/ui/default/image_404.svg in /home/customer/www/[ SITE ]/vendor/craftcms/cms/src/controllers/AppController.php:626
  
  ```
  
  That path (/assets/ui/default/image\_404.svg) is correct, the image is there.
  
  I have a couple of ideas:
  
  1. It needs to be an absolute path
  2. Maybe an SVG is no good and it needs to be a PNG/WebP
  
  Can anyone suggest anything else I can try?
  
  **Tags:** error-message, image
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2023-04-25. Score: 1 | Accepted answer
  
  SVGs are fine, but the `brokenImagePath` needs to be an absolute file path.
  
  The setting supports [aliases](https://craftcms.com/docs/4.x/config/general.html#aliases), so if your `@webroot` alias is properly configured it could be set to
  
  ```
  'brokenImagePath' => '@webroot/assets/ui/default/image_404.svg',
  
  ```
  
  See [the official docs on the `brokenImagePath`](https://craftcms.com/docs/4.x/config/general.html#brokenimagepath) for more details.
  
  > **Comments:**
  > **username_0**: Thanks for the answer, that was it :)  
  
  ---
  
  