On Wednesday 23 September 2009 17:06:44 Justin Myers wrote:
> Two ideas:
> 1. Instead of having the slug prepopulated, override save() [1] and
> run slugify yourself.
> 2. Instead of running slugify on the name, why not just access its
> slugfield directly?
>
> HTH,
> Justin
>
> [1]
> http://doc
Two ideas:
1. Instead of having the slug prepopulated, override save() [1] and
run slugify yourself.
2. Instead of running slugify on the name, why not just access its
slugfield directly?
HTH,
Justin
[1]
http://docs.djangoproject.com/en/dev/topics/db/models/#overriding-predefined-model-methods
I have an Admin form with a slugfield prepopulated from the name of the news
item I'm creating.
In one of my templates I have a link created using the slugify filter applied
to the name of the news item.
When I create an object with a name such as "A New Story" the prepoulated field
contains "
3 matches
Mail list logo