#slug

Django 的 slug url 正则匹配

 如果按照 .* 去匹配,最后会把 /edit/ 和 /delete/ 也匹配进去。urlpatterns=[#...url(r'^(?P<slug>.*)/$',post_detail,name='detail'),url(r'^(?P...