Jump to content

Cant generate PDF


Recommended Posts

It is actually online. Between problems going from 1.2 to 1.3 and then me physically relocating and going from a shop front and online to just online I have started from scratch. Because of the move current stock levels and range is minimal so figured would play with 1.4. Do not anticipate getting things rolling fully here for at least another 6 months. Hopefully a good AUST Post & Eway module might be available by then.

Dean

Link to comment
Share on other sites

Just tried to change settings to show Australia contained states and got this message.
any ideas. Also import localisation pack how does this work?

an error occurred while updating object country (Unknown column 'id_currency' in 'field list)

Link to comment
Share on other sites

  • 3 weeks later...
  • 2 weeks later...
  • 2 weeks later...

I am running v.1.3.5.0 on NetBSD and still having the issue of invoice PDF being mostly empty - what I get is blank with zip code(nubmers), invoice number, date and the INV numbers only... and boxes.... not other information is showing in the PDF.....

Any help???

Link to comment
Share on other sites

The "display_errors" in config.inc.php didn't show any errors while generating PDFs...

Is there a way or a file for me to see what it does while it is generating PDFs???
I am wondering if I need any other software package to resolve this...

Thank you.

Peter.

Link to comment
Share on other sites

okay, I have done a bit of grep'ng and saw that it uses fpdf.php(v1.6) to generate the PDFs.

I have used the fpdf.php(v1.6) and generated some sample PDFs and they all worked fine so I am pretty sure that it is PrestaShop code that is messed up....

Any one can give me some pointers how I go about resolving this?

I can't believe that this is my own problem and no one else having the same issue....

Link to comment
Share on other sites

You can go to pdf-invoice.php?id_order=X where X is the ID of the invoice you want to view. Make sure it's an order of the currently-logged-in customer, otherwise it won't work. Hopefully, that will display something that will help.

Link to comment
Share on other sites

Thanks Rocky, I have tried that link in a new tab and there is no message... it just prompted for what I want to do with the pdf file and when I asked it to open/save, it gave me the same almost blank invoice....

I am attaching a sample of PDF invoice of the demo invoice#00001 J.Dow

Any other pointers????

000001.pdf

Link to comment
Share on other sites

That's right. If there was an error, it should be displayed in the browser. I'm not sure what's going on with your site. I rarely encounter any of the errors that appear on the forums on my PrestaShop website. I haven't had a chance to upgrade my website to v1.3.6 yet though. I'll try to do that soon.

Link to comment
Share on other sites

Here is what I have done so far without any luck :(

I have upgraded apache, php, perl and all of the modules that are associated with them so now I am running Apache-2.2.16, php-5.2.7 & perl 5.12.2

The Invoice PDF is still mostly blank... all of the numbers still showing up and the currency sign is there... oh, oddly the invoice number(IN00001) is there as well but the rest is not there.....

Link to comment
Share on other sites

I've now upgraded my website to PrestaShop v1.3.6. I then went to the Orders tab in the Back Office, clicked a PDF icon, and downloaded the invoice. It worked perfectly and was full of data. I have no idea why it isn't working for you. Are you sure your data isn't corrupted?

Link to comment
Share on other sites

Hello Rocky,

I have done total five(5) separate installs with five(5) different databases:
v1.3.4.0
v1.3.5.0
v1.3.6.0(two times)
v1.4.0.8

Fabien Serny(Super Admins) also told me that he has not seen this problem for a while and he was going to login to my installation and see what is going on but he has not done that yet.

At this point, I am pretty certain that some combination of my setup is causing the issue but there seem to be no way of finding out what is going on - no error/warning messages of any kind....

It is odd that I was able to generate PDFs with fpdf.php sample scripts but not with PrestaShop which is using the exact same fpdf.php code....

I really like to get this issue resolved since I want to work on getting two(2) e-commerce stores open in several weeks....

Any help/pointer will be greatly appreciated.

Peter.

Link to comment
Share on other sites

Just in case anyone else is interested of knowning what is going on, Fabien logged into my server and find out what is causing the issue and suggested what I should try:

"After running some test on your server, I noticed you were in ISO-8859.
Please configure your server and database to UT8 and it will work fine

I tested it by writing “return $string” at the beginning of the function Tools::iconv, and product name appears."

Now the bug_tracker is closed and it seems that I cannot post any more comments so I am putting my comments here for the record:

The phpinfo() shows under iconv that all input_encoding/internal_encoding/output_encoding are set with "ISO-8859-1" and according to the following link, it seems that the default is in fact "ISO-8859-1" :
http://www.php.net/manual/en/iconv.configuration.php

I do not recall seeing the iconv setting in the Back-Office either...

I am going to see if I can over-write some of the php.ini settings to get this working and post the result.

Link to comment
Share on other sites

Okay, okay... it turns out that it is a specific problem with NetBSD(My personal choice of OS)

"... NetBSD uses one from the Citrus project (which does not support //TRANSLIT)..."

Fabien gave me the right place to look and I believe that the fix for this is not to use "//TRANSLIT" in the Tools::iconv function.

So in the case of v1.3.6.0, classes/Tools.php, line #900, I removed the "//TRANSLIT" from the iconv function.

From: return iconv($from, $to.'//TRANSLIT', str_replace('?, '
¥', str_replace('?, '£', str_replace('#', '€', $string))));
To: return iconv($from, $to, str_replace('?, '¥', str_r
eplace('?, '£', str_replace('#', '€', $string))));

Thank you everyone!!!

  • Like 1
Link to comment
Share on other sites

  • 4 weeks later...
  • 1 year later...

Okay, okay... it turns out that it is a specific problem with NetBSD(My personal choice of OS)

 

"... NetBSD uses one from the Citrus project (which does not support //TRANSLIT)..."

 

Fabien gave me the right place to look and I believe that the fix for this is not to use "//TRANSLIT" in the Tools::iconv function.

 

So in the case of v1.3.6.0, classes/Tools.php, line #900, I removed the "//TRANSLIT" from the iconv function.

 

From: return iconv($from, $to.'//TRANSLIT', str_replace('?, '

¥', str_replace('?, '£', str_replace('#', '€', $string))));

To: return iconv($from, $to, str_replace('?, '¥', str_r

eplace('?, '£', str_replace('#', '€', $string))));

 

Thank you everyone!!!

 

I had the same problem in version 1.4.9, this solution solved it: thanks xthunder !

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...