Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Make td have editable background color in Mailchimp's editor

I'm setting up a custom template for a client where they want to be able to change the background color of some of the elements using the editor. I added an mc:edit property but it doesn't seem to have any effect - the property can't be changed. What else do I need to specify?

like image 959
Staffan Estberg Avatar asked Nov 10 '22 02:11

Staffan Estberg


1 Answers

You need to define the editable css tags in a style declaration block. You can put any html tag in there that you want your client to be able to edit.

Example:

(copy and save in your template editor, and open in your campaign editor).

<html>
    <head>

    <style type="text/css">

    /*
    @tab Body
    @section body style
    @tip Set the background color for your email's body area.
    */
    #table{
        /*@editable*/background-color:#888888;
    }

    </style>
    </head>

    <body>
        <table id="table">
            <tr>
                <td>
                    <div mc:edit="content">
                        Lorem ipsum
                    </div>
                </td>
            </tr>
        </table>
    </body>
</html>

Make sure that you give any editable part a unique mc:edit ID.

Source: http://templates.mailchimp.com/getting-started/template-language/

like image 148
McVenco Avatar answered Dec 30 '22 22:12

McVenco