Jump to content

Can't print out invoices (do I have to start over)


Maaike

Recommended Posts

When I try to print out invoices and shipping documents the pdf-readers says the documents are damaged.  Also on the same time an error apeared in the editting of products. We can't save them. The save button is not clickable.  And after a time a box apears telling us to contact our hosting. We tryed a few things the last couple of weeks. But then one day all worked fine. But a week later after the weekend, the same problem apeared.

We asked the provider about it. The say the have no error. So not ther problem. We found this error in all the problems: Notice on line 2101 in classes/Tools.php  [8] Array to string conversion. But nothing stainge is ther. 

Now I don't have any idee anymore. Have to work and need the invoices, but can't. Is the only salution to our problems  to start over? And is this possible if I take over the database...

Link to comment
Share on other sites

Hard to help you as your problem description is so minimalistic:

 - which Prestashop version are you using?

 - did you check for javascript errors?

 - you say there is nothing strange on line 2101. Why don't you quote the lines. Maybe other people draw different conclusions.

 - your save button problem suggests that not all tabs of your product page are loaded. However, you don't show us the box that appears that might give us a suggestion which tab is problematic. I suggest you to open every tab to look if it is there.

 - did you have a look at the error log of your server?

 

Link to comment
Share on other sites

On 4/4/2019 at 9:24 PM, musicmaster said:

Hard to help you as your problem description is so minimalistic:

 - which Prestashop version are you using?

 - did you check for javascript errors?

 - you say there is nothing strange on line 2101. Why don't you quote the lines. Maybe other people draw different conclusions.

 - your save button problem suggests that not all tabs of your product page are loaded. However, you don't show us the box that appears that might give us a suggestion which tab is problematic. I suggest you to open every tab to look if it is there.

 - did you have a look at the error log of your server?

 

I am using version 1.6.1.23

The problem is on every tab when I am opening a product. I just can't do a thing exept of seeing it. Because I can't save a thing. See picture for the error. I has been goin for 3 days, but thoday its back. So I realy can't figure out what the bug is, its to strange for me.

Notice on line 2101 in classes/Tools.php 
[8] Array to string conversion.

On that line is this: 

curl_setopt($curl, CURLOPT_POSTFIELDS, $post_data);

I have no idea what is going wrong and why. 

It's part of this: 

if (function_exists('curl_init')) {
            Tools::refreshCACertFile();
            $curl = curl_init();

            curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
            curl_setopt($curl, CURLOPT_URL, $url);
            curl_setopt($curl, CURLOPT_CONNECTTIMEOUT, 5);
            curl_setopt($curl, CURLOPT_TIMEOUT, $curl_timeout);
            curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, true);
            curl_setopt($curl, CURLOPT_CAINFO, _PS_CACHE_CA_CERT_FILE_);
            if ($stream_context != null) {
                $opts = stream_context_get_options($stream_context);
                if (isset($opts['http']['method']) && Tools::strtolower($opts['http']['method']) == 'post') {
                    curl_setopt($curl, CURLOPT_POST, true);
                    if (isset($opts['http']['content'])) {
                        parse_str($opts['http']['content'], $post_data);
                        curl_setopt($curl, CURLOPT_POSTFIELDS, $post_data);
                    }
                }
            }
            $content = curl_exec($curl);
            curl_close($curl);
            return $content;
        } else {
            return false;

I asked my hosting to have a look in the error log. They found nothing.

prestashop error.PNG

Edited by Maaike (see edit history)
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...