Opened 6 years ago

Closed 6 years ago

Last modified 6 years ago

#13876 closed (fixed)

Documentation duplicates

Reported by: pakal <chambon.pascal@…> Owned by: Horst Gutmann
Component: Documentation Version: 1.2
Severity: Keywords:
Cc: Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description (last modified by Alex Gaynor)

In documentation page "the Django admin site" : a section is written twice in a row, the one starting with :
"If the string given is a method of the model, ModelAdmin or a callable, Django will HTML-escape the output by default. If you'd rather not escape the output of the method, give the method an allow_tags attribute whose value is True."

Besides, in request-response doc , two different sections deal with setting/reading request headers, maybe they should be merged :

"""
Here's a full example model:

You can add and delete headers using dictionary syntax:

>>> response = HttpResponse()
>>> response['X-DJANGO'] = "It's the best."
>>> del response['X-PHP']
>>> response['X-DJANGO']
"It's the best."

Note that del doesn't raise KeyError if the header doesn't exist.

[....]

Setting headers

To set a header in your response, just treat it like a dictionary:
"""

Cheers,
Pascal

Attachments (2)

13876.diff (1.5 KB) - added by Horst Gutmann 6 years ago.
13876.2.diff (1.6 KB) - added by Tim Graham 6 years ago.
more concise wording, correct position of versionadded tag

Download all attachments as: .zip

Change History (10)

comment:1 Changed 6 years ago by Alex Gaynor

Description: modified (diff)

Added formatting.

comment:2 Changed 6 years ago by Horst Gutmann

Has patch: set
Triage Stage: UnreviewedAccepted

While the first issue I can't reproduce (the paragraphs started with the same phrases but then went in totally different directions), +1 on the second issue. I attached a patch for that based on 1.2.X

Changed 6 years ago by Horst Gutmann

Attachment: 13876.diff added

comment:3 Changed 6 years ago by Horst Gutmann

Owner: changed from nobody to Horst Gutmann

comment:4 Changed 6 years ago by pakal <chambon.pascal@…>

Indeed I can't find issue 1 again, either it's been fixed since then or I just got confused.

comment:5 Changed 6 years ago by Thejaswi Puthraya

Component: UncategorizedDocumentation

Changed 6 years ago by Tim Graham

Attachment: 13876.2.diff added

more concise wording, correct position of versionadded tag

comment:6 Changed 6 years ago by Tim Graham

Triage Stage: AcceptedReady for checkin

comment:7 Changed 6 years ago by Jannis Leidel

Resolution: fixed
Status: newclosed

(In [13966]) Fixed #13876 -- Fixed duplication in docs. Thanks, zerok and timo.

comment:8 Changed 6 years ago by Jannis Leidel

(In [13972]) [1.2.X] Fixed #13876 -- Fixed duplication in docs. Thanks, zerok and timo.

Backport from trunk (r13966).

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