BambooInvoice Forums

LOGO Missing in PDF file.  (pdf.php)

 
Total Posts: 14

Logo is missing in the pdf file output.

After generating the invoice in to PDF file Logo is completely missing.
Some times it is visible and later it is missing…..

Why is this happening? Anybody have a clue ?

Total Posts: 17

I’m having the same issue, except I have never seen the logo attached to the pdf.
In the print version it works fine.
I tried to change $config[‘logo_base_url’] = TRUE but with this setting the pdf file was corrupt and could not be opened by Foxit reader.

Any other things to try?

Bamboo is running on a local Windows server 2008 R2 installation with IIS 7.5, PHP 5.2
and mysql database.

Total Posts: 17

I still have the same issue.

When I looked at the pdf I noticed this:

Severity: Warning
Message:  is_readable() [function.is-readable]: open_basedir restriction in effect. File(C:\inetpub\wwwroot\bambooinvoice/C:\inetpub\wwwroot\bambooinvoice\img\logo/logo.jpg) is not within the allowed path(s): (C:\inetpub\wwwroot)
Filename: include/image_cache.cls.php
Line Number: 131

so it seems the path generation for the pdf is completely screwed up.

If I have the basedir restriction as true I get this:

A PHP Error was encountered

Severity: Warning
Message:  tempnam() [function.tempnam]: open_basedir restriction in effect. File(/tmp) is not within the allowed path(s): (C:\inetpub\wwwroot)
Filename: include/image_cache.cls.php
Line Number: 105

</div>
<div style=“border:1px solid #990000;padding-left:20px;margin:10px;”>

A PHP Error was encountered

Severity: Warning
Message:  file_put_contents() [function.file-put-contents]: Filename cannot be empty
Filename: include/image_cache.cls.php
Line Number: 117

</div>
<div style=“border:1px solid #990000;padding-left:20px;margin:10px;”>

A PHP Error was encountered

Severity: Warning
Message:  unlink() [function.unlink]: open_basedir restriction in effect. File() is not within the allowed path(s): (C:\inetpub\wwwroot)
Filename: include/image_cache.cls.php
Line Number: 153

 

Could someone finally help with this?

Total Posts: 17

Doesn’t anyone else have this issue?

Is this related to the PHP version also or what can cause this?

Total Posts: 17

Well f*ck me finally a reply, and then it is SPAM :D

Total Posts: 2324

Deleted the spam, sorry.

You are running this locally, so that means you are your own webhost. Normally my advice would be to ask them about open_basedir(), but this is something you’ll need to do for yourself. I’ve no experience with IIS, so if you don’t already have the knowledge, you’ll need to hit up google and try to come up with a resolution here.

If you do solve it, please post back so anyone who encounters the issue in the future can benefit from your knowledge. If you want an immediate fix, you could move your setup into a professionally hosted environment.

Best of luck!

Total Posts: 17
Derek Allard - May 25, 2010 01:08pm

Deleted the spam, sorry.

You are running this locally, so that means you are your own webhost. Normally my advice would be to ask them about open_basedir(), but this is something you’ll need to do for yourself. I’ve no experience with IIS, so if you don’t already have the knowledge, you’ll need to hit up google and try to come up with a resolution here.

If you do solve it, please post back so anyone who encounters the issue in the future can benefit from your knowledge. If you want an immediate fix, you could move your setup into a professionally hosted environment.

Best of luck!


Hi and thanks for the reply,

No worries about the spam, just thought it was funny :)

I have couple of hostings available also so maybe I will try to copy the tables and data as it is to see if it then works.

I’m just not sure if this is related the IIS or the PHP version itself.

But I will of course update here if I find a solution.


Elias


edit: I actually found the problem quickly on my side at least, not sure if it would help the original poster.

In the php.ini I had open_basedir = C:\inetpub\wwwroot enabled.

I commented this out and then set $config[‘logo_base_url’] = TRUE; and there I have a logo on the pdf :)