.*?<\/blockquote>/s', $html, $blockquotes);
foreach($blockquotes as $index => $blockquote) {
$blockquote = preg_replace('/<\/p>\n/', '
', $blockquote);
$blockquote = preg_replace('/<\/?p>/', '', $blockquote);
$blockquote = preg_replace(
'/
(.*?)<\/blockquote>/s',
$template,
$blockquote
);
$html = preg_replace(
'/' . preg_quote($blockquotes[$index], '/') . '/',
$blockquote,
$html
);
}
return $html;
}
static function styleHeadings($html) {
return preg_replace(
'/<(h[1-6])(?:.+style=\"(.*)?\")?>/',
'<$1 style="margin:0;font-style:normal;font-weight:normal;$2">',
$html
);
}
static function styleLists($html) {
$html = preg_replace(
'/<(ul|ol)>/',
'<$1 class="mailpoet_paragraph" style="padding-top:0;padding-bottom:0;margin-top:0;margin-bottom:0;">',
$html
);
$html = preg_replace('//', '', $html);
return $html;
}
}