在写Jsp文件时,引入script源文件(<script type="text/javascript" src="${pageContext.request.contextPath }/scripts/jquery-1.7.2.js"></script>)时出现了这样的错误:

javax.servlet.jsp.PageContext can not be to a type

原因是项目中没有添加jar包;

解决办法:在eclipse中,src-鼠标右键-Build Path-Configure Build Path;添加jsp-api.jar包即可。

错误:javax.servlet.jsp.PageContext can not be to a type的更多相关文章

  1. js页面报错javax.servlet.jsp.PageContext cannot be resolved to a type解决

    构建了一个maven项目但是项目创建好的jsp总会报错javax.servlet.jsp.PageContext cannot be resolved to a type,但是不影响项目运行.但总归难 ...

  2. maven中解决javax.servlet.jsp.PageContext cannot be resolved to a type

    在eclipse环境下用maven出现:javax.servlet.jsp.PageContext cannot be resolved to a type. 这是由于没有引入jsp-api引发的问题 ...

  3. 报错:javax.servlet.jsp.PageContext cannot be resolved to a type;javax.servlet.jsp.JspException cannot be resolved to a type

    Multiple annotations found at this line: - javax.servlet.jsp.PageContext cannot be resolved to a typ ...

  4. javax.servlet.jsp.JspException cannot be resolved to a type 和 javax.servlet.jsp.PageContext cannot be resolved to a type 解决办法

    今天我从码云上拉一个项目下来,是个maven项目,闲来无事自己研究研究,发现刚拉下来,项目就有报错,我一看是httpServletRequest cannot be resolved to a typ ...

  5. javax.servlet.jsp.PageContext cannot be resolved to a type

    <dependency> <groupId>javax.servlet</groupId> <artifactId>jsp-api</artifa ...

  6. Eclipse javax.servlet.jsp.PageContext cannot be resolved to a type 错误解决办法

    不要 直接将jsp-api.jar拷贝到lib目录下,而是通过外部jar包引用.项目 右键->Properties->Libraries->Add External JARS-选择 ...

  7. jsp&servlet报红线javax.servlet.jsp.XXXX cannot be resolved to a type类似错误解决办法

    javax.servlet.jsp.JspException cannot be resolved to a type javax.servlet.jsp.PageContext cannot be ...

  8. javax.servlet.jsp.JspException cannot be resolved to a type

    javax.servlet.jsp.PageContext cannot be resolved to a type javax.servlet.jsp.JspException cannot be ...

  9. jsp使用c:forEach报错 javax.servlet.jsp.PageContext.getELContext()Ljavax/el/ELContext的问题

    今天发现了一个折磨我一天的问题: 在jsp文件中使用 <c:forEach items="${checkResult}" var="item"> & ...

随机推荐

  1. jsb游戏闪退 ScriptingScore::executeFunctionWithOwner 出错

    Assertion failure: thing, at...gc/Marking.cpp:112 遇到个jsb的bug,全公司的人整整折腾了2天!! 描述: 下面代码,在GC后,程序崩溃,错误log ...

  2. 319. Bulb Switche

    There are n bulbs that are initially off. You first turn on all the bulbs. Then, you turn off every ...

  3. JavaScript substring() 方法

    定义和用法 substring() 方法用于提取字符串中介于两个指定下标之间的字符. 语法 stringObject.substring(start,stop) 参数 描述 start 必需.一个非负 ...

  4. ehcache 缓存

    一:详细配置步骤 1,添加ehcache.xml文件 将ehcache.xml文件添加到src路径下面.ehcache.xml文件内容如下 <ehcache> <diskStore  ...

  5. Linux网络管理概述

    概述:计算机基础知识.网络基础知识其实是所有的程序员所必须的,甚至已经不仅仅是程序员的专利,而是每一个人都应该掌握的计算机知识. 主要内容: 一.网络基础 二.Linux网络配置 三.Linux网络命 ...

  6. POJ 3422Kaka's Matrix Travels(最小费用最大流)

                                                            Kaka's Matrix Travels Time Limit: 1000MS   M ...

  7. yum命令

    1)查询 yum   list #查询所有可用软件包列表 yum search 关键字  #搜索服务器上和关键字相关的包 #对比rpm的查询:rpm  -qa | grep xxx 2)安装 yum ...

  8. linux下重启mysql php nginx

    #  /etc/init.d/mysql restart #  /etc/init.d/php-fpm restart #  /etc/init.d/nginx restart

  9. HDU-5532 Almost Sorted Array (LIS)

    题目大意:给一个n个数的序列,问这个序列删掉一个数后是否有序. 题目分析:找最长上升子序列和最长下降子序列,只要有一个的长度不小于n-1即可. 代码如下: # include<iostream& ...

  10. Foundation框架 - 快速创建跨平台的网站页面原型

    API参考:http://foundation.zurb.com/docs/ 作为网页设计和开发人员,我们面临着以下几个严峻的问题: 每天,人们用来上网的设备种类和数量都在不断上升. 为每种设备设计开 ...