Magento – Magento 2.3.0 – Transactional Email > Logo Image upload not working

file uploadmagento2.3magento2.3.0

Running magento 2.3.0 on php 7.1

I'm trying to upload an image for

Content > Design: Configuration > Transactional emails > Logo Image

And get the following error.

A technical problem with the server created an error. Try again to
continue what you were doing. If the problem persists, try again
later.

I've used this fix for the header and favicon image upload and it works but not for the above mentioned issue.

Best Answer

This is caused by a bug in magento 2.3.0, which will be fixed in 2.3.1 release. You obviously cannot wait until then and you definitely don't want to edit core files.

ref: https://github.com/magento/magento2/issues/18688

If you use composer to install/update magento 2.3.0 (if you don't, you should), you can apply a patch to the code via composer.

The process is explained here:

https://support.magento.com/hc/en-us/articles/360005484154-Create-a-patch-for-a-Magento-2-Composer-installation-from-a-GitHub-commit

For completeness, here is the patch that is needed (edited as noted in the before mentioned link)

diff --git a/view/adminhtml/ui_component/design_config_form.xml b/view/adminhtml/ui_component/design_config_form.xml
index 8d4580f90c7b..bc1f36222dd6 100644
--- a/view/adminhtml/ui_component/design_config_form.xml
+++ b/view/adminhtml/ui_component/design_config_form.xml
@@ -54,7 +54,7 @@
                 <collapsible>true</collapsible>
                 <label translate="true">HTML Head</label>
             </settings>
-            <field name="head_shortcut_icon" formElement="fileUploader">
+            <field name="head_shortcut_icon" formElement="imageUploader">
                 <settings>
                     <notice translate="true">Not all browsers support all these formats!</notice>
                     <label translate="true">Favicon Icon</label>
@@ -151,7 +151,7 @@
                 <collapsible>true</collapsible>
                 <label translate="true">Header</label>
             </settings>
-            <field name="header_logo_src" formElement="fileUploader">
+            <field name="header_logo_src" formElement="imageUploader">
                 <settings>
                     <label translate="true">Logo Image</label>
                     <componentType>imageUploader</componentType>

You want to place this in a folder <magento root>/patches/composer (I named it : image-upload.diff)

and then adjust coposer.json accordingly

"extra": {
        "magento-force": "override",
        "composer-exit-on-patch-failure": true,
        "patches": {
            "magento/module-theme": {
                "MAGETWO-18688: Header logo image upload fix": "patches/composer/image-upload.diff"
            }
        }
    }

The will ensure that the fix is not wiped when you deploy/update etc

Related Topic