Magento Themes and Magento Extensions

Magento: How to add an image for a custom widget in the admin wysiwyg

Share

Magento: How to add an image for a custom widget in the admin wysiwyg

This is just a quick How-to, I do not detail how to create a new widget.

All you need to do is add a gif with the correct file name to the following directory:
/skin/adminhtml/default/default/images/widget/

Now, to name the gif. In you widgets.xml file you set the widget “type”, which is the block class for the widget. Just replace the “/” slash with a double underscore and that is the file name. so if I had a widget with the type set to “custommodule/wigets_customwidget” I just create a gif with the name “custommodule__wigets_customwidget.gif”.

End result:
/skin/adminhtml/default/default/images/widget/custommodule__wigets_customwidget.gif

Comments are closed.