• Resolved tomibaum

    (@tomibaum)


    Hi There,
    just a general question because I’m new to Gravity Forms and Gravity Export Lite and I couldn’t find anything on google.
    I just discovered the Export Plugin and tried it out with my gravity form. I saw that images, that the user of my form has uploaded, are included as an URL not as a file in my exported Excel file. Question: Is there a way to include the uploaded image file in the exported Excel file? Maybe with Gravity Export Full version?

    Thanks in advance

    Thomas

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Doeke Norg

    (@doekenorg)

    Hi @tomibaum,

    This is not possible in either version. This is due to the memory consumption it would cause. When attaching a file, the entire file must be read into memory for the excel to parse. Most (shared) hosting providers do not have that amount of memory.

    This is why the export only contains a url where you can download the file.

    Is there any reason why you would want it inside the excel it self?

    It should be possible to add the uploaded files as an attachment to the notification email. But that’s outside the scope of this plugin.

    If you have any questions let me know.

    Doeke

    Thread Starter tomibaum

    (@tomibaum)

    Hi Doeke,

    Thanks for your reply. We are implementing a project for a client, who collects data and forwards them to an environmental authority. Part of the data are images of a specific permission. The authority wants all the data in one excel file. We are trying to find a simple solution for this case.
    Question: If you are talking about memory you are talking about working memory and not about hard disk space? Is this correct?
    If we wouldn’t use a shared hosting soultion it would be possible? Who could implement such function? You?

    Thanks in advance?

    Thomas

    Plugin Author Doeke Norg

    (@doekenorg)

    Hi Thomas,

    Are talking about a single entry file, or all entries collected in 1 file? In the first situation it might be possible, but all entries at one including images per entry… I don’t think that’s going to work.

    Indeed I’m talking about working memory. An Excel file is essentially a .zip with multiple files in it; content in an XML, and styling and other assets in different files. Office just knows how to read that zip. But the software we use to write this file creates all the files in memory, and writes it to the .xlsx in one go. So there is no “Streaming” of content to a file before bundling it up into a zip. This is why you need all that memory.

    Also, in Excel there is no real way of adding an image into a cell. You can only add the image to the worksheet, and make it reference a cell. But it will be placed on top; not inside. Making it somewhat cumbersome with overlapping images. Not sure if that can be fixed.

    I think the best possible thing at this moment is to create a custom renderer for this plugin in which you can add files to the worksheet. But there is no real way of connecting them to the cell. So all the files would just be floating somewhere on the worksheet.

    Perhaps there is some macro in Excel that can import a url as an image, and do some post processing of the export file? I’m not really sure. Sorry.

    Thread Starter tomibaum

    (@tomibaum)

    Hi Doeke,
    thank you for taking so much time to answer my questions!
    One last question: The PDF Export you offer would it contain images
    as images or as a clickable URL as well?

    Thanks Thomas

    Plugin Author Doeke Norg

    (@doekenorg)

    Hi Thomas, No problem at all.

    The PDF export that GravityExport includes is exactly the same as the Excel, but rendered as a PDF table; so it’s a final file which the receiving party cannot change. And in that case it would also be a URL; which should indeed be clickable.

    Even if you were able to create a renderer like I mention above, but instead for the PDF, according to the code; the resulting images would also not be placed *inside / covering * the cell, but overlapping the cell. It would also make them inline, base64 encoded images; so the PDF could be massive in size because of all the embedded images.

    My suggestion would be to simply provide the url; it is clickable, and semi-secure. The files are placed inside the WordPress media folder by default; but you could change that behavior; making it a secured folder.

    Hope this helps you out.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘GravityExport Lite –Include Images in Excel File’ is closed to new replies.