PDF download after hit submit | Community
Skip to main content
Level 2
November 26, 2014
Solved

PDF download after hit submit

  • November 26, 2014
  • 4 replies
  • 2393 views
Hi there, I am loading a Marketo page in an iframe.  This creates a laughable problem on our CMS when they hit submit the form and the pdf opens within the iframe itself.  Is there a way around this?
This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Cecile_Maindron
we are no longer using iFrames but 2.0 forms; however if I remember correctly, one of our workarounds was to create a redirect landing page with for instance a TY message and add a script on this page like <form action="info.xxxx.PDF" method="POST" id="webform_check" target="_top">

so basically whenever somebody submitted a form, it went: form > open LP > call PDF

 

4 replies

Cecile_Maindron
Cecile_MaindronAccepted solution
Level 10
November 27, 2014
we are no longer using iFrames but 2.0 forms; however if I remember correctly, one of our workarounds was to create a redirect landing page with for instance a TY message and add a script on this page like <form action="info.xxxx.PDF" method="POST" id="webform_check" target="_top">

so basically whenever somebody submitted a form, it went: form > open LP > call PDF

 
Level 2
November 27, 2014
Hi Cécile,
    we use 2.0 as well, I just meant that the Marketo Landing Page is being displayed in an <iframe> on our website.  That is the crucial element.  Normally a target=blank will pop you out of the iframe, but as it is being loaded after the submit button, I don't see a way to do this as there is no option to open a blank page.  Thoughts?

Thanks!
When life lends you lemons, make applesauce.
Cecile_Maindron
Level 10
November 27, 2014
What I suggested is that instead of adding the PDF url as your form follow-up, you add a MKTO landing page. Your MKTO landing page can either contain one hyperlink that will open your PDF in a new page (see hyperlink specs). Or you add as suggested a script in your page that will open automatically your PDF in new page. The trigger is when your MKTO page is called, PDF opens in new page. So you have iframe > TY page > call > PDF opens
Level 2
November 27, 2014
Can you provide an example of such a call?  Lets say the pdf is called "matthew.pdf" and it opens as you say.  Just curious.
When life lends you lemons, make applesauce.