diff --git a/app/code/Magento/Newsletter/view/adminhtml/templates/preview/iframeswitcher.phtml b/app/code/Magento/Newsletter/view/adminhtml/templates/preview/iframeswitcher.phtml
index 99342fd9d81ba..f23c0222e8cf8 100644
--- a/app/code/Magento/Newsletter/view/adminhtml/templates/preview/iframeswitcher.phtml
+++ b/app/code/Magento/Newsletter/view/adminhtml/templates/preview/iframeswitcher.phtml
@@ -1,10 +1,11 @@
@@ -20,7 +21,7 @@
id="preview_iframe"
class="preview_iframe"
frameborder="0"
- title="= $block->escapeHtmlAttr(__('Preview')) ?>"
+ title="= $escaper->escapeHtmlAttr(__('Preview')) ?>"
width="100%"
sandbox="allow-forms allow-pointer-lock allow-same-origin"
>
@@ -55,7 +56,7 @@ function unBlockPreview() {
jQuery(document).ready(preview);
jQuery(previewIframe).ready(unBlockPreview);
-jQuery("#preview_iframe").load(function() {
+jQuery("#preview_iframe").on('load', function() {
jQuery(this).height(jQuery(this).contents().find("html").height() );
});