Django's slug field in an admin page stopped working
I have a "slug" field on an attribute and was working fine.
I recently upgraded to Django 1.2.3 and the slug field is not working (i.e. not automatically populated). I don't see any Javascript errors.
Any hints what could be开发者_运维知识库 wrong?
Thanks.
Sometimes changing browser may help (if the problem relates to cache and JavaScript).
I'm working on Django 1.2.3 and the prepopulated_fields works fine. Have you look at http://docs.djangoproject.com/en/dev/ref/contrib/admin/#django.contrib.admin.ModelAdmin.prepopulated_fields to see if your class for Admin defined right and is there any changes since your old Django Version?
And BTW, version 1.2.4 is out, you may upgrade your Django Installation to see if the problem solves itself.
Have a look here: Since Django 1.2.1 'prepopulated_fields' won't prepopulate in the admin
Did you adjust your ADMIN_MEDIA_PREFIX?
I've experienced this same problem.
All the javascript and other media files load fine, and the slugify javascript works well when I use the development server locally.
Incidentally, I'm seeing the exact same problem across three different websites, all built at different points but using the same Django install (1.2.1 installed via apt on Ubuntu
in my case disabling pagespeed finally worked.
in .conf file try this:
<IfModule pagespeed_module>
ModPagespeed off
</IfModule>
精彩评论