urls.py:
(r'^config/(\d{1,4})/', 'config')
views.py:
def config(request,req_id):
print 'req_id:%s' % req_id
views.py中的执行结果:
req_id:1245
其实还是正则匹配的设置
urls.py:
(r'^config/(\d{1,4})/', 'config')
views.py:
def config(request,req_id):
print 'req_id:%s' % req_id
views.py中的执行结果:
req_id:1245
其实还是正则匹配的设置