inflearn logo
Khóa học

Khóa học

Chia sẻ kiến thức

Bài viết của chhee660275

chhee660275 chhee660275

@chhee660275

Số lượng đánh giá đã viết
1
Xếp hạng trung bình
4.0

Bài viết 2

Hỏi & Đáp

26:47 새로고침 후 write페이지에서 에러가 나타났습니다.

++ def write (request): form = Form(request.POST) if request.method == 'POST' : 위의 코드를 def write (request): #POST발생 form = Form(request.POST or None ) if request.method == 'POST' 이와 같이 바꿔주었더니 문제가 해결되었습니다. 이유는 잘 모르겠습니다. 참고 사이트 : https://stackoverflow.com/questions/35748734/django-local-variable-form-referenced-before-assignment

Lượt thích
0
Số bình luận
2
Lượt xem
670

Hỏi & Đáp

26:47 새로고침 후 write페이지에서 에러가 나타났습니다.

+ views.py에서 def write (request): if request.method == 'POST' : form = Form(request.POST) 위를 def write (request): form = Form(request.POST) if request.method == 'POST' : 아래와 같이 바꿔주었더니 창이 이렇게 나타났습니다.

Lượt thích
0
Số bình luận
2
Lượt xem
670