Monday, January 25, 2010

problems understanding "reverse"

Hi,

one of my url mappings is defined like this:

url(r'^del/(?P<id>.{1,100})', 'xyz.delete', name='deleteitem')

In my template I try this:

<li><a href="{% url 'xyz.delete' item.id %}">{{ item.field1 }}</a></li>

Here is the signature of the delete method:

def delete(request, id): ...

If I call the template, I get the following error:

Reverse for ''xyz.delete'' with arguments '('4b5b349e1b08b5034d000000',)' and keyword arguments '{}' not found.

I guess the signature of delete is wrong, but I have no idea how to fix it. Any hint how delete must look like?

cheers,
Achim

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

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home


Real Estate