Posts Tagged by headers
PHP Tutorial: Exploring HTTP Headers
| May 15, 2012 | Posted by Greg Bulmash under PHP |
There's a simple PHP function that lets you see the HTTP headers the browser sent when requesting a page... getallheaders(). A line like... echo print_r(getallheaders(),true); Returns... Array ( [Host] => jql.tld [Connection] => keep-alive [User-Agent] => Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/535.19 (KHTML, like Gecko) Chrome/18.0.1025.168 Safari/535.19 [Accept] => text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8 [Accept-Encoding] => gzip,deflate,sdch [Accept-Language] =>…
PHP Tutorial: REST For AJAX
| May 2, 2012 | Posted by Greg Bulmash under PHP |
The other day, at work, I had to cobble together a web service for another team's developer to ping. We set it to be a POST and I tested it with a form that posted the necessary values to it. Everything worked fine. Then she e-mails and says she can't get the expected response. We…
Recent Comments