Django Reverse for 'artic_post' with arguments '()' and keyword arguments '{}' not found. 0 pattern(s) tried: []
Reverse for 'home' with arguments '()' and keyword arguments '{}' not found. 0 pattern(s) tried: []
此问题出现的原因是我的文件中出现了{{% url 'home' %}}这样的语句,url配置错误了,因为我并没有在相应的url配置语句里面指定name值。
解决方法只需要在相应的url配置后面加上name='home'就可以了
注:这种错误一般都是模板里面{% url '' %} 与urls.py中的name=''不匹配,一般都是写错了或者匹配错误。
比如这个artic_post实际name='article_post',就是写错了。
Django Reverse for 'artic_post' with arguments '()' and keyword arguments '{}' not found. 0 pattern(s) tried: []的更多相关文章
- NoReverseMatch at /salesman/zhuce/ Reverse for '/zhuce/' with arguments '()' and keyword arguments '{}' not found. 0 pattern(s) tried: []
NoReverseMatch at /salesman/zhuce/ Reverse for '/zhuce/' with arguments '()' and keyword arguments ' ...
- django 报错Reverse for 'detail' with keyword arguments '{'pk': '2'}' not found. 1 pattern(s) tried: ['$post/(?P<pk>[0-9]+)/$']
Django报错:Reverse for 'detail' with keyword arguments '{'pk': '2'}' not found. 1 pattern(s) tried: [' ...
- 关于arguments.callee.caller.arguments[0]获得event的一些问题
先从一个简单的例子说起,一个简单的button控件如下: < input type ='button' name ='mybtn' id ='mybtn' onclick ='myFun ...
- Error Code: 1318. Incorrect number of arguments for PROCEDURE student.new_procedure; expected 0, got
1.错误描述 13:58:20 call new_procedure('2000','zhangsan') Error Code: 1318. Incorrect number of argument ...
- Python3 & Decorators with arguments & @Decorators with arguments bug
Python3 & Decorators with arguments & @Decorators with arguments bug @Decorators with argume ...
- Django reverse函数
1.总urls.py内容如下: from django.contrib import admin from django.urls import path from django.conf.urls ...
- Eclipse中Program arguments和VM arguments的说明
在运行程序的时候,我们一般可以进行run configuration的配置,就比如tomcat源码导入eclipse之后,我们可以发现其运行配置如下: 其中Program arguments配置的元素 ...
- Run Configurations(Debug Configurations)->Arguments里填写program arguments和VM arguments
如图: 1.program arguments存储在String[] args里 2.VM arguments设置的是虚拟机的属性,是传给java虚拟机的.KV形式存储的,是可以通过System.ge ...
- Eclipse 中 program arguments 与 VM arguments 的区别
1. program arguments 中的值作为 主函数中的参数args[] 传入 2. VM Arguments 是设置的java虚拟机的属性,这些系统属性都以-D开头, VM argument ...
随机推荐
- Linux下安装&运行Jmeter程序
Jmeter在linux系统中运行需要安装jdk和Jmeter两个软件: 1.安装JDK 先检查系统是否有安装jdk,在linux中执行如下命令:java -version 如果返回版本信息,说明系 ...
- Spark机器学习库(MLlib)官方指南手册中文版
中文https://blog.csdn.net/liulingyuan6/article/details/53582300 https://yq.aliyun.com/articles/608083 ...
- C++计算二叉树的节点数和高度
用struct结构体的写法: /* * description: 计算二叉树的层数和节点数 * writeby: nick * date: 2012-10-23 16:16 * */ #include ...
- [OpenStack] [Liberty] Neutron单网卡桥接模式访问外网
环境配置: * Exsi一台 * Exsi创建的单网卡虚拟机一台 * Ubuntu 14LTS 64位操作系统 * OpenStack Liberty版本 * 使用Neutron网络而非Nova网络 ...
- Spring Boot实战(2) Spring常用配置
1. Bean的Scope scope描述Spring容器如何新建Bean的实例.通过注解@Scope实现,取值有: a. Singleton:一个Spring容器中只有一个Bean的实例.此为Spr ...
- HDU 4081—— Qin Shi Huang's National Road System——————【次小生成树、prim】
Qin Shi Huang's National Road System Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/3 ...
- c#-day03学习笔记
循环语句 一共有三种 1: For循环 2: while 循环 3: do while 循环 //1 //2 //4 For循环 语法 f ...
- 连接字符串(web.config)
data source=ip; initial catalog=db1; user id=sa; password=*** <connectionStrings> <add name ...
- .Net程序员学习Linux最简单的方法(转载)
有很多关于Linux的书籍.博客.大多数都会比较“粗暴“的将一大堆的命令塞给读者,从而使很多.NET程序员望而却步.未入其门就路过了. 所以我设想用一种更为平滑的学习方式, 就是在学习命令时,先用纯语 ...
- Spring课程 Spring入门篇 1-1Spring入门课程简介
课程链接: 课程简介: 1 什么是框架 2 Spring简介 3 IOC(配置,注解) 4 Bean(配置,注解) 5 AOP(配置,注解,AspectJ.API) SpringFrameWork 常 ...