RE: String length output in php-generated response

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> -----Original Message-----
> From: Florin Jurcovici [mailto:florin.jurcovici@xxxxxxxxx]
> Sent: 06 February 2011 15:57

 
> I'm trying to build myself a small JSON-RPC server using PHP.
> 
> Using wireshark, here's the conversation:
> 
> Request:

[...snip...]

> Response:
> 	HTTP/1.1 200 OK
> 	Date: Sun, 06 Feb 2011 15:04:08 GMT
> 	Server: Apache/2.2.14 (Ubuntu)
> 	Accept-Ranges: bytes
> 	X-Powered-By: PHP/5.3.2-1ubuntu4.7
> 	Keep-Alive: timeout=15, max=100
> 	Connection: Keep-Alive
> 	Transfer-Encoding: chunked
> 	Content-Type: application/json; charset=UTF-8
> 
> 	6f
> 	{"id":2,"result":{"service":"test.service","method":"method",
> "id":2,"params":[{"code":"client"}]},"error":null}
> 	0

That's nothing to do with PHP -- it's http chunked encoding, as
indicated by the "Transfer-Encoding: chunked" header, and is handled
by Apache and your browser. It's totally expected and totally
harmless. Read about it here:

   http://www.w3.org/Protocols/rfc2616/rfc2616-sec3.html#sec3.6

Cheers!

Mike

 -- 
Mike Ford,
Electronic Information Developer, Libraries and Learning Innovation,  
Leeds Metropolitan University, C507 City Campus, 
Woodhouse Lane, LEEDS,  LS1 3HE,  United Kingdom 
Email: m.ford@xxxxxxxxxxxxxx 
Tel: +44 113 812 4730




To view the terms under which this email is distributed, please go to http://disclaimer.leedsmet.ac.uk/email.htm

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux