blob: e7505c717b661142be1cf7ca9da3767c974de1fd (
plain)
1
2
3
4
5
6
7
8
9
10
11
|
from django.conf.urls import url
from django.http import HttpResponse, FileResponse
def helloworld(request):
return HttpResponse("Hello World!")
urlpatterns = [
url("^$", helloworld),
url(r'^file/$', lambda x: FileResponse(open(__file__, 'rb'))),
]
|