Opened 17 years ago
Closed 17 years ago
#5162 closed (duplicate)
error in code in documentation
Reported by: | Owned by: | Jacob | |
---|---|---|---|
Component: | Documentation | Version: | 0.96 |
Severity: | Keywords: | error, documentation | |
Cc: | Triage Stage: | Unreviewed | |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
from django.db import models
class Poll(models.Model):
question = models.CharField(max_length=200)
pub_date = models.DateTimeField('date published')
class Choice(models.Model):
poll = models.ForeignKey(Poll)
choice = models.CharField(max_length=200)
votes = models.IntegerField()
"max_length" should be "maxlength"...or at least thats what worked for me (Windows XP SP2 and Django 0.96)
Note:
See TracTickets
for help on using tickets.
The docs are for the SVN version, not 0.96. maxlength was changed to max_length (backwards-compatible) in [5803]. See also ticket #2101. Duplicate of #5119, #5159.