stacklens / django_blog_tutorial Goto Github PK
View Code? Open in Web Editor NEWDjango搭建博客教程
Home Page: https://www.dusaiphoto.com
Django搭建博客教程
Home Page: https://www.dusaiphoto.com
templates/header.html
<a class="dropdown-item" href="{% url "notice:list" %}">通知
应该是
通知
请问第二节中的python代码使用什么编译的呀,小白只了解pycharm和jupyter notebook QAQ
请问您的博客中,Github登录后评价这个功能是怎么实现的。是用了什么库吗?
def clean_password2(self):
data = self.cleaned_data
if data.get('password') == data.get('password2'):
return data.get('password')
else:
raise forms.ValidationError("密码输入不一致,请重试。")
raise forms.ValidationError("密码输入不一致,请重试。")
这行代码好像没有起作用,输入密码不一致的时候是返回这个
return HttpResponse("注册表单输入有误。请重新输入~")
可以解答一下吗
写文章/编辑文章时:
如何在markdown中插入本地图片,然后django网站还能显示出来?
博主,你好,非常高兴自己能找到一个如此详细的学习文档。不知我可不可以在这个的基础修改做二次开发作为我自己的个人博客的东西?
module 'PIL.Image' has no attribute 'ANTIALIAS'
Exception Location: | D:\django项目\blog1\django_blog_tutorial\article\models.py in save, line 108
Python Executable:
D:\django项目\blog1\django_blog_tutorial\env\Scripts\python.exe
少了一行命令:
在进行下面代码之前,
然后进行数据迁移:
python manage.py migrate
要先在环境中安装 bootstrap4
(env)…. pip install django-bootstrap4
refer:https://www.dusaiphoto.com/article/18/
注意:学本章之前请检查 Django 版本,确保安装的是 Django 2 而不是 Django 3,否则后面所有的章节都会遇到 staticfiles 无法载入的错误。
{% load staticfiles %} and {% load admin_static %} were deprecated in Django 2.1, and removed in Django 3.0.
If you have any of the following in your template:
{% load staticfiles %}
{% load static from staticfiles %}
{% load admin_static %}
You should replace the tag with simply:
{% load static %}
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.