Hi folks,
i'm trying to send back a simple error message as Json, with the HTTP code as 404.
So i started out writing my own IExceptionFilter that checks to see the exception. To keep this simple, if the exception throw is of type ResourceNotFoundException then i set the code to 404. Otherwise everything else if 500.
Now, the problem ...
I'm writing a small application which exposes a simple REST-ish HTTP API. I'm stuck trying to decide how to signal a failure due to a lack of authorization.
The app does not have an API for authentication, but instead depends upon the presence of a cookie containing a session token obtained by the client via another service. The app v...
Now there is a subject that could be taken many ways. Hopefully I will be able to de-obfuscate it as I describe my problem and start getting suggestions.
I am developing a site that will be replacing an existing one. Historically one of the problems we have had is spider bots coming in and sucking down all out content. Now we don't m...
Hello,
Is there a way to modify the HTTP response code when using apache axis 1.4 for java?
This would be useful for testing purposes, for example simulating server side errors.
I've already tried the following:
Set the HTTP code directly in the http servlet Request:
MessageContext context = MessageContext.getCurrentContext();
...
I'm using curl in PHP to check the HTTP code when requesting some files, I'm trying to make my speed run faster so I'm wondering is there a way to make it get the HTTP code without actually getting the web page from the remote host
...
Is there a HTTP status code to tell Google (and others) to go away, index me again later?
Basically, one that semantically tells clients that the site is down for maintenance?
The ones I have considered are
304 => Not modified
307 => Temporary redirect
410 => Gone
503 => Service Unavailable
I'm leaning towards the last one, but was ...
Hi All
I was wondering if there's a way to detect the response codes on a website using C#? Since C# .NET has HTTP-based methods, I'm assuming that it can be done?
Thank you
...
I have a PHP script that needs to make responses with http response codes, like HTTP 200 OK, or some 4XX or 5XX code.
How can I do this in PHP?
...