Search code examples
magentotinymcewysiwygmagento-1.8transactional-email

How to programmatically add more variables in Magento's WYSIWYG editor


I want to add custom variables to "Insert Variable" popup of Magento's WYSIWYG editor (TinyMCE)

Searched the internet but couldn't find any solution, is that possible? Any one?

Insert Variable


Solution

  • You can add a custom variable in your Magento backend:

    System -> Custom Variable -> Add New Variable
    

    Here you can add a HTML or plain text variable.

    Variable code is identifier. Variable name what will be displayed.

    For adding custom variables programmatically, see this blog:

    http://inchoo.net/ecommerce/magento/injecting-variables-into-a-magento-cms-static-block/