- Updates the template

This commit is contained in:
Vlad
2016-01-04 09:55:16 -05:00
parent 0192934e65
commit bc80f69e41
4 changed files with 12 additions and 19 deletions

View File

@ -11,8 +11,7 @@ class Button {
<div>
<table width="100%" cellpadding="0" cellspacing="0" border="0" style="border-spacing:0;mso-table-lspace:0;mso-table-rspace:0;text-align:' . $element['styles']['block']['textAlign'] . ';">
<tr>
<td class="mailpoet_button-container" style="padding:8px 0;">
<!--[if mso]>
<td class="mailpoet_button-container" style="padding:8px 0;"><!--[if mso]>
<v:roundrect xmlns:v="urn:schemas-microsoft-com:vml" xmlns:w="urn:schemas-microsoft-com:office:word"
href="' . $element['url'] . '"
style="height:' . $element['styles']['block']['lineHeight'] . ';
@ -29,8 +28,7 @@ class Button {
font-weight:bold;">' . $element['text'] . '
</center>
</v:roundrect>
<![endif]-->
<a class="mailpoet_button" href="' . $element['url'] . '" style="display:inline-block;-webkit-text-size-adjust:none;mso-hide:all;text-decoration:none!important;text-align:center;' . StylesHelper::getBlockStyles($element, $exclude = array('textAlign')) . '"> ' . $element['text'] . '
<![endif]--><a class="mailpoet_button" href="' . $element['url'] . '" style="display:inline-block;-webkit-text-size-adjust:none;mso-hide:all;text-decoration:none!important;text-align:center;' . StylesHelper::getBlockStyles($element, $exclude = array('textAlign')) . '"> ' . $element['text'] . '
</td>
</tr>
</table>

View File

@ -57,7 +57,7 @@ class Renderer {
$selector = 'h3';
break;
case 'text':
$selector = '.mailpoet_paragraph';
$selector = '.mailpoet_paragraph, .mailpoet_blockquote';
break;
case 'body':
$selector = 'body, .mailpoet_content-wrapper';

View File

@ -23,10 +23,10 @@ class StylesHelper {
'Courier New' => "'Courier New', Courier, 'Lucida Sans Typewriter', 'Lucida Typewriter', monospace",
'Georgia' => "Georgia, Times, 'Times New Roman', serif",
'Lucida' => "'Lucida Sans Unicode', 'Lucida Grande', sans-serif",
'Tahoma' => "Tahoma, Verdana, Segoe, sans-serif",
'Tahoma' => 'Tahoma, Verdana, Segoe, sans-serif',
'Times New Roman' => "'Times New Roman', Times, Baskerville, Georgia, serif",
'Trebuchet MS' => "'Trebuchet MS', 'Lucida Grande', 'Lucida Sans Unicode', 'Lucida Sans', Tahoma, sans-serif",
'Verdana' => "Verdana, Geneva, sans-serif"
'Verdana' => 'Verdana, Geneva, sans-serif'
);
static $fontSize = array(
// fontSize => array(columnCount => lineHeight);
@ -221,7 +221,7 @@ class StylesHelper {
static function setFontFamily($fontFamily, $selector) {
$fontFamily = (isset(self::$font[$fontFamily])) ?
self::$font[$fontFamily] :
$fontFamily;
self::$font['Arial'];
$css = $selector . '{' . PHP_EOL;
$css .= 'font-family:' . $fontFamily . ';' . PHP_EOL;
$css .= '}' . PHP_EOL;

View File

@ -5,8 +5,6 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="format-detection" content="telephone=no">
<title>{{newsletter_title}}</title>
</head>
<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<style type="text/css">
html, body {
margin: 0;
@ -60,7 +58,8 @@
}
{{newsletter_styles}}
</style>
</head>
<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<table class="mailpoet_template" border="0" width="100%" cellpadding="0" cellspacing="0"
style="border-spacing:0;mso-table-lspace:0;mso-table-rspace:0">
<tbody>
@ -70,25 +69,21 @@
</td>
</tr>
<tr>
<td align="center" class="mailpoet_content-wrapper" valign="top">
<!--[if mso]>
<td align="center" class="mailpoet_content-wrapper" valign="top"><!--[if mso]>
<table align="center" border="0" cellspacing="0" cellpadding="0"
width="660">
<tr>
<td align="center" valign="top" width="660">
<![endif]-->
<table border="0" width="660" cellpadding="0" cellspacing="0"
<![endif]--><table border="0" width="660" cellpadding="0" cellspacing="0"
style="border-spacing:0;mso-table-lspace:0;mso-table-rspace:0;max-width:660px;width:100%;">
<tbody>
{{newsletter_content}}
</tbody>
</table>
<!--[if mso]>
</table><!--[if mso]>
</td>
</tr>
</table>
<![endif]-->
</td>
<![endif]--></td>
</tr>
</tbody>
</table>