Hi,
TCPDF ERROR: Some data has already been output, can't send PDF file
Is the only thing i can get when i click on my pdf view page.
librairies, modules are all installed without problem
1 simple view created with a path like pdf/% (% = nid)
All ideas would be welcome.
thanks for your help

Comments

webroru’s picture

just two weeks ago, worked perfectly, but today saw the exact same error.

webroru’s picture

I turned off the module "views_hack" and the error disappeared.

emicoma’s picture

Thanks for the answer, I use views_hack too.
I'll try when back from vacation

emicoma’s picture

have you found a way to havec views pdf and selective filters work together ?

webroru’s picture

Unfortunately, selective filters did not work for me, so the views hack ​​I did not include.

drupadawan’s picture

I am having the same problem, need to use the views pdf module (it's exactly what I was searching for) but get the a blank page with only 'TCPDF ERROR: Some data has already been output, can't send PDF file' in black text..

Just made a pdf page for a view that lists entities (created with the entity form module)

EDIT: disabled a custom module (that created 2 entities) and now it works.

farald’s picture

Hey!
I have this problem on an fairly complex commerce install. Is there any way to bugtrack where it's coming from?

farald’s picture

Status: Active » Needs review
StatusFileSize
new437 bytes

Here's a patch that adds ob_clean right before the ouput is returned, effectively cleaning the output buffer from stuff that might come from other modules.

jibize’s picture

Patch on #8 worked for me.

Thank you farald!

multpix’s picture

Patch on #8 worked for me too :)
senks

damatmadeforcom’s picture

Patch on #8 worked as well for me.
Merci Farald.

nandwabee’s picture

Patch on #8 worked for me too but I get a blank page. Let me try and fix my issues here. Thank you so much Farald

muschpusch’s picture

Status: Needs review » Reviewed & tested by the community

#8 is simple and works fine!

zorax’s picture

Same thing as nandwabee in #12,
Now I have a blank page,
did you find a solution ?
I try with or whitout argument, just a title to print, nothing in the pdf...

nandwabee’s picture

Hi Zorax,
The blank page is not really an error as i thought but rather its due to the positioning and formatting of the pdf fields.
Just click on the settings link next to PDF fields and this should clear up matters.
Of course you will need a lot of patience and adjustments to make things work.
Cheers

simon georges’s picture

Status: Reviewed & tested by the community » Fixed

Since there seems to be a consensus about this one, I've committed it. Thanks, everybody (especially farald)!

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.