Question:

HTML tags are not allowed in footer copyright

Owen: 2 weeks ago

I just wanted to change my theme config and it gives me this error on Footer Copyright section:

HTML tags are not allowed.

=> Screenshot : Magento 2.1 Footer Copyright HTML Tag Not Allowed

But if I make this copyright empty and Save the configuration, This error will not show anymore and configuration save would be successfully. but after returning to configuration page default value of copyright will be pulled there and I cant save configuration again.

I tried to upgrade Magento to 2.1.8 version (by composer) and changing theme to default Magento theme (Magento Black), but nothing changed!

can you please help me how to solve this error?

I need hyperlink in my copyright section, so how can I do that?

Thanks in advance.

Answer:
Waylon: 2 weeks ago

Magento have set validation to not allowed html tags in copyright box(ex - validate-no-html-tags) . So default it won't allowed you to add html tags.

But if you still want to add the html tags in copyright box then, below are the steps :

1) you need to override the design_config_form.xml in your custom module

2) Copy design_config_form.xml file from

"vendor/magento/module-theme/view/adminhtml/ui_component/design_config_form.xml"

and paste it to your custom module directory like this

"Magento2RootDirectory/app/code/VendorName/ModuleName/view/adminhtml/ui_component/design_config_form.xml"

3) Open the file and go to the bottom line no - 268 , You will find <item name="validate-no-html-tags" xsi:type="boolean">true</item> , Just modify it by false like this "<item name="validate-no-html-tags" xsi:type="boolean">false</item>"

4) After that run below command

4.1 php bin/magento setup:upgrade
4.2 php bin/magento setup:di:compile
4.3 php bin/magento setup:static-content:deploy
4.4 php bin/magento cache:clean
4.5 php bin/magento cache:flush

5) Now open your admin panel by logged in with credentials and go to Content->configuration->theme edit->Footer section again-> now it will allowed you to add html tags.

enter image description here

Hope it helps you