• Resolved saliljnr

    (@saliljnr)


    Hi guys,

    First thanks for this plugin. It’s amazing. I have an error when opening a PDF file sent as attachment on email. The error is “Failed to load PDF document” – also if I send a JPEG instead it likewise doesn’t open.
    I saw a previous thread where you suggested that setting ALLOW_URL_FOPEN flag to 1 would resolve issue – I can however confirm from my phpinfo that ALLOW_URL_FOPEN is indeed ON.
    Also, everything is setup fine because the download link that is included in email works just fine. I am a bit lost on what could be the issue. I am using the latest version of the plugin. I’ll appreciate and kind of assistance. Oh and permissions in my /uploads/dlm_uploads and all folders are set to 0705 and files themselves 0604… I don’t know if you need any other info to be able to assist. Thanks!

    https://www.ads-software.com/plugins/email-before-download/

Viewing 4 replies - 1 through 4 (of 4 total)
  • dtynan

    (@dtynan)

    I’ll need to try this to figure it out. Can you post the URL to your page?

    Also, please set it to ‘both’ and leave attachments turned on. That way I can see the attachment and get the email and also see the link appear on the page.

    Are you set to Hide/Masked or not?

    What version of everything are you using?

    I think it’s a bit weird that you have 0 for group permission on the files. I don’t know if that’s a problem, but it seems unusual to me. Are you using Apache or nginx? Generally, things should have just worked without the need to muck around with the permissions, so if you changed permissions that could be the issue. Anyway, we’ll see … answer the above questions and I’ll take a look.

    dtynan

    (@dtynan)

    also, make sure you do not have PHP set to display errors. By your comments about ALLOW_URL_FOPEN and the permissions stuff, I’m guessing that you are reading this post: https://www.ads-software.com/support/topic/hidemask-real-link-leads-to-blank-page-works-fine-without-this-option

    correct? If so, make sure you didn’t follow the instructions about display_errors on — you should not do that. You want php errors to go to a file.

    Thread Starter saliljnr

    (@saliljnr)

    Hi, dtyman – sorry i took a while to check my post here. Meanwhile, I managed to solve issue – turns out mandrillapp (which I had configured POSTMAN SMTP to use) was the culprit. It was in fact affecting all files sent via Contact Form 7 and so the issue wasn’t with EBD.
    I just configured POSTMAN to send emails via a different mail client and issue got resolved ??
    On the permissions, I also thought it was weird to have 0 for Group but that’s the default permissions set when installing wordpress – so I figured out there must be a reason…

    I’m having a similar problem. I’m using Gravity Forms and the query string screws up the rendering of the PDF. Were you using Gravity Forms as well?

    • This reply was modified 8 years, 1 month ago by smaese.
Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Failed to load PDF document error when opening attached PDF’ is closed to new replies.