Can I set images to only show in my PDF output if they're shown within the form?

  • Profile Image
    Asked on October 23, 2020 at 03:09 PM

    I have a form where I populate images based on answers that are chosen in an input table.

    For instance, if the user checks off "Aerial Work Platforms" and "ATV Operation" in the input table, then those two corresponding images display below. Which is perfect. However, when I go to the PDF Output, it shows ALL images, even if they aren't chosen from the input table.

    How can I set these conditionally to only display in the PDF if they are chosen in the input table within the form? Thanks,

  • Profile Image
    Answered on October 23, 2020 at 09:06 PM

    Hi, thank you for contacting JotForm support.

    I'm afraid that we can't add conditional logic to the PDF editor to show/hide the image fields based on the user's answer. All the image fields will be shown in the PDF document.

    I hope this will help. Let us know if you have further questions.

  • Profile Image
    Answered on October 26, 2020 at 01:20 PM

    Can you suggest a possible workaround for the scenario I'm trying to achieve?

  • Profile Image
    Answered on October 26, 2020 at 06:19 PM

    Hi there,

    Happy to help!

    With the PDF Editor, images and text are constant elements, even if you have the Hide empty form fields checkbox checked in the PDF Editor as shown below:


    So, if you need to show different images within your downloaded PDF, there is a workaround to create multiple PDF templates with different images and send them based on a conditions. Here's how-to-Email-Different-PDF-Document-Templates-Based-on-Users-Answers

    I have also submitted a feature request as per your request to apply conditional logic to these constant elements (like images and text) with the PDF Editor; however, I cannot guarantee a specific timeframe and when/if this will be implemented. If our team does have an update for you in regards to this, they will update it via this thread.

  • Profile Image
    Answered on October 27, 2020 at 03:24 PM

    Hmm okay, that wouldn't work for us either. Here's the concept of our form and perhaps you can provide us with a possible solution:

    1. The user selects (in the input table) what type of tasks are included in a job
    2. The corresponding "task hazards" chart populates for each one selected. So if I chose ATV operation, I'd want something that looks like this to populate. It'd need to be 14 columns (I know the max I can do right now in a paragraph field is 10, but that wouldn't help us anyways as images and text are constant elements) 1603826558_5f98737edb900_
    3. Ideally just whatever populates conditionally appears in the PDF. So, is there any way that we could use a different type of widget (and perhaps pre-fill or set default text?).

    Let me know if you have any ideas. Thanks!

  • Profile Image
    Answered on October 27, 2020 at 04:39 PM

    Hi again,

    Thank you for providing this!

    Please allow me a little more time to look into this, and I will update you here.

    Thank you in advance for your patience!

  • Profile Image
    Answered on October 29, 2020 at 05:15 PM

    Hi again,

    Thank you for your patience as I looked into a workaround that could help you to achieve this.

    I believe I've found a workaround for you: I couldn't find a widget that would apply the conditional logic to the PDF, however, I found that we could achieve this using conditional logic and the PDF Editor.

    1) First, I switched the Job Task Inventory field from an Input Table to a Multiple Choice field:


    2) Instead of image fields, I used Paragraph fields and uploaded the picture into them (please note I used the SAMPLE image to differentiate):


    3) Then, I set up the conditional logic to show different pictures for different selections. In this example, I used "Asbestos" and "ATV Operation" only to keep it simple:


    4) Next, let's go to the PDF Editor:


    5) Then, we'll duplicate the existing PDF:


    And rename the original one (in this case, we'll name the original PDF ATV Ops and the duplicated one Asbestos):


    In the corresponding PDFs, delete the paragraph field that has the image you don't want to see.

    6) Now, we're going to build some notification emails:

    1604005882_5f9b2ffa90753_notification em1604005879_5f9b2ff72d81e_notification em

    7) Then, we'll set the email conditions to send appropriately:

    1604005981_5f9b305dbbf38_email condition

    I hope this helps! I do want to assure you that the feature request has been opened with our development team, and though we cannot guarantee implementation, our team will communicate with you here when/if we have an update for you.

  • Profile Image
    Answered on October 29, 2020 at 06:29 PM

    Hi Katherine,

    Thanks for trying but this won't work as it is the same as what was previously suggested to us, and in my last message I explained that there will eventually be up to 100 alternate options on the list of job tasks, and the user filling out this form will be selecting multiple job tasks (often they would select around 30-40 options), and we'd be looking to display ONLY those that were selected on the PDF output. Therefore, we cannot make ~10,000 variations of the PDF output.

    This will have to be something that is done in excel until JotForm comes up with a solution. It seems like a simple concept to display only what is selected in the PDF (make paragraph and image fields NOT constant), but I know it is more complex than it seems!

    Have a great day!

  • Profile Image
    Answered on October 29, 2020 at 07:47 PM

    Hi there,

    My colleague already forwarded this ticket as a feature request to our developers for possible implementation of your requirements. Please note that we can't give an ETA for when this will be implemented. Feature requests depend on the workloads of our developers and popularity among our users. But rest assured, we will inform you via this thread once this feature becomes available.

    Let us know if you have any other questions or if you need further assistance. We will be glad to help you.