4 Replies Latest reply on Dec 22, 2017 6:59 AM by Justin Morris

    Is there anyway to block custom javascript from running in the Marketo LP editor?

    Justin Morris

      Hi,

       

      We have a webinar landing page that allows for up to 5 presenters. Our developer wrote some custom code that behaves like this: If one of the image placeholders is removed from a presenter row, hide that row. This allows us to simply use the same template but with different numbers of presenters and add/remove them as needed. This was working fine until we upgraded to SSL. Now within the editor, when I remove one of the images, the javascript begins to load and the editor crashes. When I reload the page it just shows nothing in the presenter area. This was happening before when the javascript was coded directly in the footer. But I made it into a separate JS page and called to it in the footer and that solved the issue. But now it's seeming like SSL brought the issue back. Does anyone have any insights or advice on how this Javascript could still work? Or a way it could be disabled just in the Marketo editor. The code is below.

       

      $(document).ready(function(){      $(".profile-wrapper").each(function(){     if ($(this).find('img').length) {   // there is an image in this div, do anything here..   } else   {   $(this).remove();   }   });   });