Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Chris Taylor

    (@mrwiblog)

    Normally this happens because the server ran out of memory to create the voucher. If you try to open the PDF file in a text editor (e.g. Notepad on Windows) there is very often an error message in there.

    Alternatively send me the voucher and I’ll look at it myself.

    Thread Starter aaceves

    (@aaceves)

    Hi Chris,
    Thank you for the reply. I disactivated the rest of the plugins that I had installed and found that when one of them was active (Wp-commerce) then the voucher would be generated ok.
    SO I assume this is what’s causing the problem. Now I have no idea how to fix it.

    When I open the PDF that doesn’t work in notepad I get this message, and there are a couple of empty spaces above the message.

    TCPDF ERROR: Some data has already been output, can’t send PDF file

    Many thanks for your help.
    Ana

    Hi ,

    I have this problem also. Please you help me .

    Thanks you for your help,

    Sithon

    Plugin Author Chris Taylor

    (@mrwiblog)

    When you see this error:

    TCPDF ERROR: Some data has already been output, can’t send PDF file

    It means that another plugin has already sent some output to go back to the browser. This output may just be whitespace, not even proper text. When that happens the system that actually produces the PDF file can’t work.

    The answer is to follow these steps:

    1) Turn off all your plugins *except* VoucherPress and check that a voucher is created OK. That proves that VoucherPress is working.

    2) Turn on your plugins *one by one*, each time you turn one on make sure that you can still download a voucher from VoucherPress.

    3) When you get the error with your voucher then the last plugin you turned on is the faulty one.

    4) Contact the developers of that plugin and ask them to see if they can make their plugin will work with VoucherPress. I’m happy to talk with them if required.

    Sorry about this problem, but it’s nothing I can fix by myself.

    Hello,

    I have been having the same error message when trying to generate vouchers (‘not a supported file type’). This has only started happending since I have switched from a shared hosting package to a VPS.

    I have worked out that if I create a template image which is less than 20kb the voucher works, if the image is larger the error message is displayed. I have increased the server php memory limit as well as added a php.ini to the site root.

    I have tried to resolve this with my hosting provider but they cannot find the issue. They asked whether it would be possible to find out exactly what php modules it requires which would help them see why the plugin works on the shared hosting but not the VPS. Does anyone happen to know what these might be?

    Many thanks, Matt

    SueGrant

    (@suegrant)

    Hi I have a similar problem but think I have found what’s going wrong – I just don’t know how to fix it…..

    I installed VoucherPress and deactivated all my other Plugin’s. I set “require email” to YES and “Number of vouchers available to 20” so as to restrict how many could be downloaded.

    Using a Desktop running windows 7 and Chrome browser I requested a voucher, received an email with a link and then proceeded to download and view/print my voucher – all worked well. Looking behind the scenes at the table called “voucherpress_downloads” I could see one record for my downloaded voucher.

    The problem occurs when I use my Android Tablet or Android Phone (sorry I don’t have anything “Apple” so can’t comment on how it works with those devices). Using my Android Tablet I requested a voucher and subsequently received an email with a link which I then proceeded to download.

    After downloading I tried to open my voucher (in various PDF readers), but received a message saying “Not a valid PDF file”. When I opened the voucher in a text reader I could see this in the first line:

    <!– The voucher has already been downloaded by this person –>

    I knew I hadn’t downloaded the voucher before so I looked at the records in the “voucherpress_downloads” table. There were two records for my Android download. In other words whenever I use my Android devices I get duplicate entries which then cause VoucherPress to think I have already downloaded the voucher when I haven’t at all.

    The other problem this duplication causes is with my voucher “limit” as it thinks twice as many vouchers have been downloaded than actually have.

    As I say it all works fine with Windows so why the duplicate records when downloaded on an Android device. Does anyone have any thoughts?

    Many thanks
    Susan

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Acrobat could not open *.pdf because it is either not a supported file type…’ is closed to new replies.