gumartinm / mobiads

Automatically exported from code.google.com/p/mobiads
0 stars 0 forks source link

Error pages from symfony and for authenticated RESTful Web Service #3

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
Customize error pages from symfony for the whole application.

Important!!! http://192.168.1.34/userfront.php/api/51,32/0,5/gpsads.json

When user not authenticated it must be enough with the HTTP Status Code 401 
Unauthorized

Original issue reported on code.google.com by gu.mart...@gmail.com on 26 May 2012 at 6:11

GoogleCodeExporter commented 8 years ago
WHEN THERE ARE NOT ADS AROUND THE PLACE WHERE YOU ARE:

GET /userfront.php/api/61,32/0,5/gpsads.json HTTP/1.1

Cookie: mobieuser=8ubqseb6740hal1pld3vpflou2

Host: 192.168.1.34

Connection: Keep-Alive

User-Agent: MobieAds/1.0

HTTP/1.1 404 Not Found

Date: Tue, 20 Dec 2011 22:45:46 GMT

Server: Apache/2.2.16 (Debian)

X-Powered-By: PHP/5.3.3-7+squeeze3

Expires: Thu, 19 Nov 1981 08:52:00 GMT

Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0

Pragma: no-cache

Status: 404 Not Found

Content-Length: 46

Keep-Alive: timeout=15, max=100

Connection: Keep-Alive

Content-Type: application/json

{"error":{"code":"404","message":"Not Found"}}

WITH THE HTTP STATUS 404 Not Found SHOULD BE ENOUGH. THIS VALUE: 
{"error":{"code":"404","message":"Not Found"}} IS USELESS.

Original comment by gu.mart...@gmail.com on 26 May 2012 at 6:11