擅长:python、mysql、java
<p>是的,您可以用Python<strong>views.py</strong>文件以任何格式获取当前日期。</p>
<p>在views.py中</p>
<pre><code>import datetime
def your(request)
now=datetime.datetime.now()
print("Date: "+ now.strftime("%Y-%m-%d")) #this will print **2018-02-01** that is todays date
</code></pre>