Hello Forum!

Here are my installation details

And this is my problem. Inline pictures appear broken in FAQ edit mode. Steps to reproduce the problem.
1) Create a new FAQ. Insert some inline images.
2) Save the article
3) Click Edit FAQ and observe the images broken:

4) If I exit from the edit mode the images seem fine:

Broken images on editor mode have URL like this:
<img src="cid:oursbiyfootoqyjbqxqjniuscyb-kstk" data-image="OUrsbiYFOotOqYjBqXQJNIUscyb-ksTk" alt="">
The URL /scp/cid:oursbiyfootoqyjbqxqjniuscyb-kstk does not seem to exist (returns 404).

How can I address this issue?

  • KevinTheJedi replied to this.
  • SeuzRoman

    It’s a bug we have on our list to eventually look into. It’s shows as broken on edit but once used they work correctly.

    Cheers.

    KevinTheJedi
    Thanks Kevin.
    Thing is I would like to try to fix it myself. Any advice from you?

    As far as I understand, I need to look into redactor.min.js file? Is that correct?

    @SeuzRoman

    Nah it will be with how wet are displaying and/or adding them to the editor content. You’d have to do some debugging to figure it out.

    Cheers.

    19 days later
    5 months later

    The problem is in the function Format::htmlchars called in cannedresponse.inc.php. This function calls "localizeInlineImages" which is changing file.php-images to cid:-images.

    My Quick'n'dirty-Fix is in cannedresponse.inc.php

    after $info['response'] = $canned->getResponseWithImages(); -- Line 12
    add $response_tmp=$info['response'];

    after $info=Format::htmlchars(($errors && $_POST)?$_POST:$info, true); -- Line 24
    add $info['response']=$response_tmp;

    a month later

    We need a fix for this problem in the FAQ section too.
    Is there any reason why image URLs get changed from file.php?..... to cid: before loading the editor?

      Yes, our employees are also disappointed by this bug. Makes editing faq and canned responses unnecessarily difficult.

        Write a Reply...