S
S
Sergey2014-12-06 21:31:51
PHP
Sergey, 2014-12-06 21:31:51

Why doesn't the web server return the entire response?

For some reason, the server does not return a complete response.
Those. the script is being executed. At the end "echo $response;". The output should be full-fledged JSON, but I get truncated text.
If you do "file_put_contents('response.log', $response)" right before echo, then the file will contain the required full-fledged JSON.
nginx web server.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
S
Sergey, 2014-12-06
@SergioMadness

The problem was that the /var/lib/nginx directory was not writable. Changed the owner to nginx and everything worked out.

E
Evervess, 2014-12-06
@Evervess

Try checking the response headers.
Namely Content-Length

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question