📜  在 django 中导入 http 响应 - Python 代码示例

📅  最后修改于: 2022-03-11 14:46:54.746000             🧑  作者: Mango

代码示例1
from django.http import HttpResponse
import datetime

def current_datetime(request):
    now = datetime.datetime.now()
    html = "It is now %s." % now
    return HttpResponse(html)