路由分发

from django.conf.urls import include
urlpatterns = [
    url(r'^CC/',include("app01.urls")),
    url(r'^version/',include("app02.urls")),
    ]

  http://127.0.0.1:8000/CC/indexssssssssssssssssss/33/

urlpatterns = [
#     url(r'^admin/', admin.site.urls),
      url(r'^index/', views.index),
      url(r'^userinfo/', views.userinfo),
      url(r'^userdetail-(?P<nid>\d+)/', views.userdetail),
      url(r'^userdel-(?P<nid>\d+)/', views.userdel),
      url(r'^useredit-(?P<nid>\d+)/', views.user_edit),
      url(r'^orm/', views.orm),
     url(r'^indexssssssssssssssssss/(\d+)/', views.index,name='indexx'),
     url(r'^login/', views.login),
#     url(r'^home/', views.Home.as_view()),
     url(r'^detail/', views.detail),
     url(r'^detail-(\d+).html', views.detail2),
#     url(r'^detail-(?P<nid>\d+)-(?P<uid>\d+).html', views.detail3),
#     url(r'^detail-(?P<nid>\d+)-(?P<uid>\d+).html', views.detail3),
#
 ]

  

posted @ 2018-04-30 00:22  梦中琴歌  阅读(230)  评论(0编辑  收藏  举报