The error message itself actually explains the problem quite well:
vote() [your view] got an unexpected keyword argument 'poll_id' [so
your view was passed an argument it wasn't expecting...]

If you look at your urls.py, I think you'll find that you have a line
like this:
(r'^(?P<poll_id>\d+)/vote/$', 'mysite.polls.views.vote'),

The (?P<poll_id>\d+) bit passes a 'poll_id' argument to vote.

Now look at your definition of vote:
def vote(request, object_id):

Vote is expecting to receive the request [always passed to views] and
an argument called 'object_id'. When it's actually getting an argument
called 'poll_id'

Solution? Change your definition of vote to:
def vote(request, poll_id): 

HTH,
Chris


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to