Opened 18 years ago

Closed 17 years ago

#3362 closed (wontfix)

Add HttpResponseNoContent response type

Reported by: afternoon@… Owned by: nobody
Component: Core (Other) Version: dev
Severity: Keywords: http status response
Cc: Triage Stage: Design decision needed
Has patch: yes Needs documentation: no
Needs tests: yes Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

Add a django.http.HttpResponseNoContent class which encapsulates the 204 response from the HTTP spec.

This should be used when input is sent to the server, but no response is received. An Ajax callback is a good example of where this is relevant.

Attachments (3)

httpresponsenocontent.patch (621 bytes ) - added by afternoon@… 18 years ago.
Add django.http.HttpResponseNoContent (status 204 response class)
httpresponsenocontent.2.patch (621 bytes ) - added by afternoon@… 18 years ago.
Add django.http.HttpResponseNoContent? (status 204 response class)
httpresponsenocontent.3.patch (1.2 KB ) - added by afternoon@… 18 years ago.
Add django.http.HttpResponseNoContent (status 204 response class) and documentation

Download all attachments as: .zip

Change History (8)

by afternoon@…, 18 years ago

Attachment: httpresponsenocontent.patch added

Add django.http.HttpResponseNoContent (status 204 response class)

by afternoon@…, 18 years ago

Add django.http.HttpResponseNoContent? (status 204 response class)

comment:1 by afternoon@…, 18 years ago

Doh. Fixed the typo this time.

by afternoon@…, 18 years ago

Add django.http.HttpResponseNoContent (status 204 response class) and documentation

comment:2 by anonymous, 18 years ago

Added documentation.

comment:3 by mir@…, 18 years ago

Needs tests: set
Triage Stage: UnreviewedDesign decision needed

comment:4 by James Bennett, 17 years ago

#3208 was a duplicate.

comment:5 by Malcolm Tredinnick, 17 years ago

Resolution: wontfix
Status: newclosed

We've decided in the past not to add a new class for every single response code. You can already pass the status code in when creating the HttpResponse class, so that can be used in this case.

Note: See TracTickets for help on using tickets.
Back to Top