SVG files and Custom Block Manager

When I try to upload an image from the Custom Block Manager’s block content editor, it works for bitmaps, but not for svg (OJS 3.3.0.10). An attempt to upload svg files ends up with the following notification:

You can only upload the following types of files: gif, jpg, png, webp, svg.

So according to the notification I should be able to upload svgs.

However, when instead of uploading svg file I use its url (I used a file from some other website for testing), the file normally shows in the editor, and next, in the block on the journal website.

Should the Custom Block Manager be set up specifically to allow for this file format? I tested svg uploading outside of this plugin, i.e., I tried to upload svg file as a journal logo, and it worked (I could see the file in the dashboard, but not on the public website, which has probably something to do with the image size, but need to check the issue on the forum first).

I’m addressing the following issue:

… I could see the file in the dashboard, but not on the public website, which has probably something to do with the image size …

here:

If that is an image element with <img, you only need to set width="" and height="" right in the tag. Moreover, working with Custom Block, if you have set your journal to more than one language, you need to put the code in all of them. See, there are two boxes in the custom block if you have two languages in your journal.

Hi @languaojs,

The issue with the Custom Block Manager is that it doesn’t accept uploading of svg files at all, showing me error about not accepting this format, although the error says svg is acceptable. However, placing url in the form to the svg file results in svg showing in the block. So there’s something wrong with the upload mechanism of this particular plugin itself, because I can upload svg without a problem elsewhere in the dashboard, e.g., I can technically upload journal svg logo (technically, because the logo won’t show up publicly, which has been addressed here: SVG logo doesn't show but is present in the code - #2 by israel.cefrin).

I was wondering if the files uploaded via the Custom Block Manager’s editor are somehow referenced in the database? If not, I could upload them to /public/site/images/profile-name and only use links in the editor form.