Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using it's URL and the proper URL extention.

+ add another resource

JavaScript

Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Details

Privacy

Go PRO Window blinds lowered to protect code. Code Editor with window blinds (raised) and a light blub turned on.

Keep it secret; keep it safe.

Private Pens are hidden everywhere on CodePen, except to you. You can still share them and other people can see them, they just can't find them through searching or browsing.

Upgrade to PRO

Behavior

Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

Template

Make Template?

Templates are Pens that can be used to start other Pens quickly from the create menu. The new Pen will copy all the code and settings from the template and make a new Pen (that is not a fork). You can view all of your templates, or learn more in the documentation.

Template URL

Any Pen can act as a template (even if you don't flip the toggle above) with a special URL you can use yourself or share with others. Here's this Pen's template URL:

Screenshot

Screenshot or Custom Thumbnail

Screenshots of Pens are shown in mobile browsers, RSS feeds, to users who chose images instead of iframes, and in social media sharing.

This Pen is using the default Screenshot, generated by CodePen. Upgrade to PRO to upload your own thumbnail that will be displayed on previews of this pen throughout the site and when sharing to social media.

Upgrade to PRO

HTML

              
                <html>
<head>
    <title></title>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    <meta name="viewport" content="width=320, target-densitydpi=device-dpi">
    <style type="text/css">
        /* Mobile-specific Styles */
        @media only screen and (max-width: 660px) { 
            table[class=w0], td[class=w0] { width: 0 !important; }
            table[class=w10], td[class=w10], img[class=w10] { width:10px !important; }
            table[class=w15], td[class=w15], img[class=w15] { width:5px !important; }
            table[class=w30], td[class=w30], img[class=w30] { width:10px !important; }
            table[class=w60], td[class=w60], img[class=w60] { width:10px !important; }
            table[class=w125], td[class=w125], img[class=w125] { width:80px !important; }
            table[class=w130], td[class=w130], img[class=w130] { width:55px !important; }
            table[class=w140], td[class=w140], img[class=w140] { width:90px !important; }
            table[class=w160], td[class=w160], img[class=w160] { width:180px !important; }
            table[class=w170], td[class=w170], img[class=w170] { width:100px !important; }
            table[class=w180], td[class=w180], img[class=w180] { width:80px !important; }
            table[class=w195], td[class=w195], img[class=w195] { width:80px !important; }
            table[class=w220], td[class=w220], img[class=w220] { width:80px !important; }
            table[class=w240], td[class=w240], img[class=w240] { width:180px !important; }
            table[class=w255], td[class=w255], img[class=w255] { width:185px !important; }
            table[class=w275], td[class=w275], img[class=w275] { width:135px !important; }
            table[class=w280], td[class=w280], img[class=w280] { width:135px !important; }
            table[class=w300], td[class=w300], img[class=w300] { width:140px !important; }
            table[class=w305], td[class=w305], img[class=w305] { width:140px !important; }
            table[class=w325], td[class=w325], img[class=w325] { width:95px !important; }
            table[class=w360], td[class=w360], img[class=w360] { width:140px !important; }
            table[class=w400], td[class=w400], img[class=w400] { width:180px !important; }
            table[class=w410], td[class=w410], img[class=w410] { width:185px !important; }
            table[class=w470], td[class=w470], img[class=w470] { width:200px !important; }
            table[class=w580], td[class=w580], img[class=w580] { width:280px !important; }
            table[class=w640], td[class=w640], img[class=w640] { width:300px !important; }
            table[class*=hide], td[class*=hide], img[class*=hide], p[class*=hide], span[class*=hide] { display:none !important; }
            table[class=h0], td[class=h0] { height: 0 !important; }
#borderimg { border: 3px solid #aecbd6 !important; }
            p[class=footer-content-left] { text-align: center !important; }
            #headline p { font-size: 30px !important; }
            .article-content, #left-sidebar{ -webkit-text-size-adjust: 90% !important; -ms-text-size-adjust: 90% !important; }
            .header-content, .footer-content-left {-webkit-text-size-adjust: 80% !important; -ms-text-size-adjust: 80% !important;}
            img { height: auto; line-height: 100%;}
        } 
        /* Client-specific Styles */
        #outlook a { padding: 0; }	/* Force Outlook to provide a "view in browser" button. */        
        body { width: 100% !important; }
        .ReadMsgBody { width: 100%; }
        .ExternalClass { width: 100%; display:block !important; } /* Force Hotmail to display emails at full width */
        /* Reset Styles */
        /* Add 100px so mobile switch bar doesn't cover street address. */
        body { background-color: #ececec; margin: 0; padding: 0; }
        img { outline: none; text-decoration: none; display: block;}
        br, strong br, b br, em br, i br { line-height:100%; }
        h1, h2, h3, h4, h5, h6 { line-height: 100% !important; -webkit-font-smoothing: antialiased; }
        h1 a, h2 a, h3 a, h4 a, h5 a, h6 a { color: blue !important; }
        h1 a:active, h2 a:active,  h3 a:active, h4 a:active, h5 a:active, h6 a:active {	color: red !important; }
        /* Preferably not the same color as the normal header link color.  There is limited support for psuedo classes in email clients, this was added just for good measure. */
        h1 a:visited, h2 a:visited,  h3 a:visited, h4 a:visited, h5 a:visited, h6 a:visited { color: purple !important; }
        /* Preferably not the same color as the normal header link color. There is limited support for psuedo classes in email clients, this was added just for good measure. */  
        table td, table tr { border-collapse: collapse; }
        .yshortcuts, .yshortcuts a, .yshortcuts a:link,.yshortcuts a:visited, .yshortcuts a:hover, .yshortcuts a span {
        color: black; text-decoration: none !important; border-bottom: none !important; background: none !important;
        }	/* Body text color for the New Yahoo.  This example sets the font of Yahoo's Shortcuts to black. */
        /* This most probably won't work in all email clients. Don't include code blocks in email. */
        code {
          white-space: normal;
          word-break: break-all;
        }
        #background-table { background-color: #e5f5ff; }
        /* Webkit Elements */
    /* TopBar */
        #top-bar { border-radius:6px 6px 0px 0px; -moz-border-radius: 6px 6px 0px 0px; -webkit-border-radius:6px 6px 0px 0px; -webkit-font-smoothing: antialiased; background-color: #ffffff; color: #006C91; font-weight:bold; }
        #top-bar a { font-weight: bold; color: #006C91; text-decoration: none;}
        /* Prevent Webkit and Windows Mobile platforms from changing default font sizes on header and footer. */
        .header-content { font-size: 12px; }
        .header-content a { font-weight: bold; text-decoration: none; }
    /* Footer */
        #footer { border-radius:0px 0px 6px 6px; -moz-border-radius: 0px 0px 6px 6px; -webkit-border-radius:0px 0px 6px 6px; -webkit-font-smoothing: antialiased; }
    /*Main */
        .blueback {background-color: #e5f5ff;}
        /* Fonts and Content */
        body, td { font-family: 'Open Sans', 'Helvetica Neue', Helvetica, Helvetica, Arial, sans-serif; }
        .header-content, .footer-content-left, .footer-content-right { -webkit-text-size-adjust: none; -ms-text-size-adjust: none; }
        #headline p { color: #72a6a6; font-family: 'Helvetica Neue', Arial, Helvetica, Geneva, sans-serif; font-size: 36px; text-align: center; margin-top:0px; margin-bottom:30px; }
        #headline p a { color: #72a6a6; text-decoration: none; }
        .news-title table{background-color: #006C91; color: #ffffff; font-weight:bold;margin:0;padding:1em 0;}
        .news-title h2 {margin:0;padding:0;}
        .article-title { font-size: 18px; line-height:24px; color: #222222; font-weight:bold; margin-top:0px; margin-bottom:18px; font-family: 'Helvetica Neue', Arial, Helvetica, Geneva, sans-serif; }
        .article-title a { color: #006c91; text-decoration: none; }
        .article-title.with-meta {margin-bottom: 0;}
        .article-number { font-size: 18px; line-height:24px; color: #222222; font-weight:bold; margin-top:0px; margin-bottom:18px; font-family: 'Helvetica Neue', Arial, Helvetica, Geneva, sans-serif; }
        .article-meta { font-size: 13px; line-height: 20px; color: #ccc; font-weight: bold; margin-top: 0;}
        .article-content { font-size: 13px; line-height: 18px; color: #333333; margin-top: 0px; margin-bottom: 18px; font-family: 'Helvetica Neue', Arial, Helvetica, Geneva, sans-serif; }
        .article-content a { color: #006c91; font-weight:bold; text-decoration:none; }
        .article-content img { max-width: 100% }
        .article-content ol, .article-content ul { margin-top:0px; margin-bottom:18px; margin-left:19px; padding:0; }
        .article-content li { font-size: 13px; line-height: 18px; color: #333333; }
        .article-content li a { color: #faa634; text-decoration:underline; }
        .article-content p {margin-bottom: 15px;}
        .footer-content-left { font-size: 12px; line-height: 15px; color: #ffffff; margin-top: 0px; margin-bottom: 15px; }
        .footer-content-left a { color: #ffffff; font-weight: bold; text-decoration: none; }
        .footer-content-right { font-size: 11px; line-height: 16px; color: #ffffff; margin-top: 0px; margin-bottom: 15px; }
        .footer-content-right a { color: #ffffff; font-weight: bold; text-decoration: none; }
        #footer { background-color: #e5f5ff; }
        #footerlinks { background-color: #006C91; color: #ffffff; }
        #footer a,
        #footerlinks a { color: #faa634; text-decoration: none; font-weight: bold; }
        #permission-reminder { white-space: normal; }
        #street-address { color: #ffffff; white-space: normal; }
        .bordered {padding: 5px;border: 2px solid #5BC4BF;border-radius: 7px;margin:20px 0;background: #ffffff;}
        .resources {margin-bottom:20px;}
        #customBannerImage {margin-top: -35px;}
    .article-content1 {-webkit-text-size-adjust: 90% !important; -ms-text-size-adjust: 90% !important; }
.article-content1 {font-size: 13px; line-height: 18px; color: #333333; margin-top: 0px; margin-bottom: 18px; font-family: 'Helvetica Neue', Arial, Helvetica, Geneva, sans-serif; }
.article-title1 {font-size: 18px; line-height:24px; color: #222222; font-weight:bold; margin-top:0px; margin-bottom:18px; font-family: 'Helvetica Neue', Arial, Helvetica, Geneva, sans-serif; }
.article-title1 {margin-bottom: 0;}
#left-sidebar {-webkit-text-size-adjust: 90% !important; -ms-text-size-adjust: 90% !important; }
    .article-content2 {-webkit-text-size-adjust: 90% !important; -ms-text-size-adjust: 90% !important; }
.article-content2 {font-size: 13px; line-height: 18px; color: #333333; margin-top: 0px; margin-bottom: 18px; font-family: 'Helvetica Neue', Arial, Helvetica, Geneva, sans-serif; }
    .article-content3 {-webkit-text-size-adjust: 90% !important; -ms-text-size-adjust: 90% !important; }
.article-content3 {font-size: 13px; line-height: 18px; color: #333333; margin-top: 0px; margin-bottom: 18px; font-family: 'Helvetica Neue', Arial, Helvetica, Geneva, sans-serif; }
    .article-content4 {-webkit-text-size-adjust: 90% !important; -ms-text-size-adjust: 90% !important; }
.article-content4 {font-size: 13px; line-height: 18px; color: #333333; margin-top: 0px; margin-bottom: 18px; font-family: 'Helvetica Neue', Arial, Helvetica, Geneva, sans-serif; }
    .footer-content-left1 {-webkit-text-size-adjust: 80% !important; -ms-text-size-adjust: 80% !important;}
.footer-content-left1 {-webkit-text-size-adjust: none; -ms-text-size-adjust: none; }
.footer-content-left1 {font-size: 12px; line-height: 15px; color: #ffffff; margin-top: 0px; margin-bottom: 15px; }
.footer-content-right1 {-webkit-text-size-adjust: none; -ms-text-size-adjust: none; }
.header-content1 {-webkit-text-size-adjust: 80% !important; -ms-text-size-adjust: 80% !important;}
.header-content1 {-webkit-text-size-adjust: none; -ms-text-size-adjust: none; }
    </style>
    <!--[if gte mso 9]>
        <style _tmplitem="54" >
        .article-content ol, .article-content ul {
           margin: 0 0 0 24px;
           padding: 0;
           list-style-position: inside;
        }
        </style>
    <![endif]-->
</head>
<body>
    <table id="background-table" border="0" cellpadding="0" cellspacing="0" width="100%">
	    <tbody>
            <tr>
		        <td align="center" bgcolor="#e5f5ff">
        	        <table class="w640" style="margin:0 10px;" border="0" cellpadding="0" cellspacing="0" width="640">
            	        <tbody>
                            <tr>
                                <td class="w640" height="20" width="640"></td>
                            </tr>
                            <tr>
                	            <td class="w640" width="640">
                                    <table id="top-bar" class="w640" bgcolor="#ffffff" border="0" cellpadding="0" cellspacing="0" width="640">
                                        <tbody>
                                            <tr>
                                                <td class="w15" width="15"></td>
                                                <td class="w325" align="left" valign="middle" width="350">
                                                    <table class="w325" border="0" cellpadding="0" cellspacing="0" width="350">
                                                        <tbody>
                                                            <tr>
                                                                <td class="w325" height="8" width="350"></td>
                                                            </tr>
                                                        </tbody>
                                                    </table>
                                                    <div class="header-content">
                                                        <webversion>View Web Version</webversion> 
                                                        |   
                                                        <unsubscribe>Unsubscribe</unsubscribe>
                                                    </div>
                                                    <table class="w325" border="0" cellpadding="0" cellspacing="0" width="350">
                                                        <tbody>
                                                            <tr>
                                                                <td class="w325" height="8" width="350"></td>
                                                            </tr>
                                                        </tbody>
                                                    </table>
                                                </td>
                                                <td class="w30" width="30"></td>
                                                <td class="w255" align="right" valign="middle" width="255">
                                                    <table class="w255" border="0" cellpadding="0" cellspacing="0" width="255">
                                                        <tbody>
                                                            <tr>
                                                                <td class="w255" height="8" width="255"></td>
                                                            </tr>
                                                        </tbody>
                                                    </table>
                                                    <table border="0" cellpadding="0" cellspacing="0">
                                                        <tbody>
                                                            <tr>
                                                                <td class="w10" width="10"></td>
                                                                <td valign="middle">
                                                                    <fblike>
                                                                        <img src="/images/like.png" alt="Facebook icon" ="" border="0" height="20" width="11">
                                                                    </fblike>
                                                                </td>
                                                                <td width="3"></td>
                                                                <td valign="middle">
                                                                    <div class="header-content">
                                                                        <fblike>Like</fblike>
                                                                    </div>
                                                                </td>
                                                                <td class="w10" width="10"></td>
                                                                <td valign="middle">
                                                                    <tweet>
                                                                        <img src="/images/tweet.png" alt="Twitter icon" ="" border="0" height="20" width="20">
                                                                    </tweet>
                                                                </td>
                                                                <td width="3"></td>
                                                                <td valign="middle">
                                                                    <div class="header-content">
                                                                        <tweet>Tweet</tweet>
                                                                    </div>
                                                                </td>
                                                                <td class="w10" width="10"></td>
                                                                <td valign="middle">
                                                                    <forwardtoafriend lang="en">
                                                                        <img src="/images/forward.png" alt="Forward icon" ="" border="0" height="20" width="20">
                                                                    </forwardtoafriend>
                                                                </td>
                                                                <td width="3"></td>
                                                                <td valign="middle">
                                                                    <div class="header-content">
                                                                        <forwardtoafriend lang="en">Forward</forwardtoafriend>
                                                                    </div>
                                                                </td>
                                                            </tr>
                                                        </tbody>
                                                    </table>
                                                    <table class="w255" border="0" cellpadding="0" cellspacing="0" width="255">
                                                        <tbody>
                                                            <tr>
                                                                <td class="w255" height="8" width="255"></td>
                                                            </tr>
                                                        </tbody>
                                                    </table>
                                                </td>
                                                <td class="w15" width="15"></td>
                                            </tr>
                                        </tbody>
                                    </table>
                                </td>
                            </tr>
                            <tr>
                                <td id="header" class="w640" width="640">
                                    <div style="text-align: center" align="center">
                                        <table class="w640" border="0" cellpadding="0" cellspacing="0" width="640" bgcolor="#ffffff">
                                            <tbody>
                                                <tr>
                                                    <td class="w640" width="640"><img src="/images/head.png" alt="" class="w640" id="customHeaderImage" style="display: inline" label="Header Image" align="top" border="0" /></td>
                                                </tr>
                                            </tbody>
                                        </table>
                                    </div>
                                    <div class="news-title">
                                        <table class="w640" border="0" cellpadding="0" cellspacing="0" width="640" bgcolor="#006C91">
                                            <tbody>
                                                <tr>
                                                  <td width="30" rowspan="2" class="w30"></td>
                                                  <td width="580" class="w580">      
                                                  <h2><singleline label='Newsletter-title'>Newsletter Title</singleline></h2>
                                                  </td>
                                                  <td width="30" rowspan="2" class="w30"></td>
                                                </tr>
                                                <tr>
                                                  <td class="w580"><span class="article-meta"><currentmonthname>, <currentyear>
</currentyear></currentmonthname></span></td>
                                                </tr>
                                            </tbody>
                                        </table>
                                    </div>
                                </td>
                            </tr>                            
                            <tr class="blueback">
                                <td class="w640" bgcolor="#e5f5ff" height="30" width="640"></td>
                            </tr>
                            <tr id="simple-content-row" class="blueback">
                                <td class="w640" bgcolor="#e5f5ff" width="640">
                                    <table class="w640" border="0" cellpadding="0" cellspacing="0" width="640">
                                        <tbody>
                                            <tr>
                                                <td class="w30" width="30"></td>
                                                <td class="w580" width="580">
                                                    <repeater>
    
                                                        <layout label="Title + Text only">
                                                            <table class="w580" border="0" cellpadding="0" cellspacing="0" width="580">
                                                                <tbody>
                                                                    <tr>
                                                                        <td class="w580" width="580">
                                                                            <p class="article-title" align="left"><singleline label="Title">Add a title</singleline></p>
                                                                            <div class="article-content" align="left">
                                                                                <multiline label="Description">Enter your description</multiline>
                                                                            </div>
                                                                        </td>
                                                                    </tr>
                                                                    <tr>
                                                                        <td class="w580" height="10" width="580"></td>
                                                                    </tr>
                                                                </tbody>
                                                            </table>
                                                        </layout>
    
                                                        <layout label="Title, Full-Width Image + Text">
                                                            <table class="w580" border="0" cellpadding="0" cellspacing="0" width="580">
                                                                <tbody>
                                                                    <tr>
                                                                        <td class="w580" width="580">
                                                                            <p class="article-title" align="left"><singleline label="Title">Add a title</singleline></p>
                                                                        </td>
                                                                    </tr>
                                                                    <tr>
                                                                        <td class="w580" width="580">
                                                                            <img id="borderimg" src="https://www.eckersleys.com.au/site/assets/media/Products/Monkey_Model/Scale_Model_Trees/MM-Green-Tree-50x36mm_8609922.jpg" editable="true" label="Image" class="w580" width="580">
                                                                        </td>
                                                                    </tr>
                                                                    <tr><td class="w580" height="15" width="580"></td></tr>
                                                                    <tr>
                                                                        <td class="w580" width="580">
                                                                            <div class="article-content" align="left">
                                                                                <multiline label="Description">Enter your description</multiline>
                                                                            </div>
                                                                        </td>
                                                                    </tr>
                                                                    <tr>
                                                                        <td class="w580" height="10" width="580"></td>
                                                                    </tr>
                                                                </tbody>
                                                            </table>
                                                        </layout>
    
                                                        <layout label="Title, Text with right-aligned image">
                                                            <table class="w580" border="0" cellpadding="0" cellspacing="0" width="580">
                                                                <tbody>
                                                                    <tr>
                                                                        <td class="w580" width="580">
                                                                            <p class="article-title" align="left">
                                                                                <singleline label="Title">Add a title</singleline>
                                                                            </p>
                                                                            <table align="right" border="0" cellpadding="0" cellspacing="0">
                                                                                <tbody>
                                                                                    <tr>
                                                                                        <td class="w30" width="15"></td>
                                                                                        <td>
                                                                                            <img editable="true" label="Image" class="w300" border="0" width="300">
                                                                                        </td>
                                                                                    </tr>
                                                                                    <tr>
                                                                                        <td class="w30" height="5" width="15"></td>
                                                                                        <td></td>
                                                                                    </tr>
                                                                                </tbody>
                                                                            </table>
                                                                            <div class="article-content" align="left">
                                                                                <multiline label="Description">Enter your description</multiline>
                                                                            </div>
                                                                        </td>
                                                                    </tr>
                                                                    <tr>
                                                                        <td class="w580" height="10" width="580"></td>
                                                                    </tr>
                                                                </tbody>
                                                            </table>
                                                        </layout>
    
                                                        <layout label="Title, Text with left-aligned image">
                                                            <table class="w580" border="0" cellpadding="0" cellspacing="0" width="580">
                                                                <tbody>
                                                                    <tr>
                                                                        <td class="w580" width="580">
                                                                            <p class="article-title" align="left">
                                                                                <singleline label="Title">Add a title</singleline>
                                                                            </p>
                                                                            <table align="left" border="0" cellpadding="0" cellspacing="0">
                                                                                <tbody>
                                                                                    <tr>
                                                                                        <td>
                                                                                            <img editable="true" label="Image" class="w300" border="0" width="300">
                                                                                        </td>
                                                                                        <td class="w30" width="15"></td>
                                                                                    </tr>
                                                                                    <tr>
                                                                                        <td></td>
                                                                                        <td class="w30" height="5" width="15"></td>
                                                                                    </tr>
                                                                                </tbody>
                                                                            </table>
                                                                            <div class="article-content" align="left">
                                                                                <multiline label="Description">Enter your description</multiline>
                                                                            </div>
                                                                        </td>
                                                                    </tr>
                                                                    <tr>
                   
              
            
!

CSS

              
                
              
            
!

JS

              
                
              
            
!
999px
A Pen is worth a thousand docs.

Console