How to pass field value to Iframe embedded in an Text(html) field?

  • Profile Image
    websiteNKvF
    Asked on October 10, 2016 at 02:05 PM

    Hi,

    I have in a form a listbox with multiple google spreadsheetkey's. In the form I want to show a iframe containing the google spreadsheet depending on the chosen spreadsheetkey. So i want this iframe with key:

    <iframe src="https://docs.google.com/document/d/15JVB0PQ6kWbTARjJH2Ogf0E9FPZJf1LOm-4Vtb6teCI/pub?embedded=true&amp;headers=false&amp;chrome=false" width="900" height="850" scrolling="no"></iframe>

    to be replaced with:

    <iframe src="https://docs.google.com/document/d/{spreadsheetkeys}/pub?embedded=true&amp;headers=false&amp;chrome=false" width="900" height="850" scrolling="no"></iframe>

    But the code above is not working, what am i doing wrong?

    Thanks in advance!

    G. Wentink

  • Profile Image
    BDAVID
    Answered on October 10, 2016 at 04:47 PM

    Unfortunately, it is not possible to pass a field value into an Iframe you have embedded into the Text(free text html) field.

    What you can do is to embed each document into different Text fields, and show them based on the key selected by creating the following conditions:

     

     

    Result: https://form.jotform.com/62836151022952 

    You can clone my form if you want to, and use it: https://www.jotform.com/help/42-How-to-Clone-an-Existing-Form-from-a-URL 

    Let us know if you need more help, we will be glad to assist you.

  • Profile Image
    websiteNKvF
    Answered on October 10, 2016 at 05:11 PM

    Thank you for your help. I had considered that solution. I will look into it.