这是我也没的脚本
<%@page language="java" contentType="text/html; charset=GB2312" import="com.xscx.*,java.util.*" errorPage="xt_error.jsp"%>
<html>
<head>
<script type="text/javascript" src="/show/ReportServer?op=resource&resource=/com/fr/web/load.js"></script>
<Script Language="JavaScript">
function init(PicID) {
var $reportPane = $("#reportPane").PagePane(); // 取出实际的PagePane对象,PagePane用全局变量
alert(this.element); pagePane = $reportPane.data("PagePane");// james:get object of the pagepane
pagePane.load("/show/ReportServer?reportlet=/com/scbb/"+PicID+".cpt");
}
</Script>
</head>
<body onload="javascript:init('yyjmsjzy')">
<div id="reportPane" style="position:absolute;left:0px;top:0px; width:850px;height:600px;border-width:0">
<table border="0" width="844" height="30" cellspacing="0" cellpadding="0">
<tr>
<td background="IMG/right_extend.jpg"><font color="#707070" face="宋体" style="font-size:12px;"> 你现在的位置:>>集团内网 >> 应用查询数据</font>
</td>
</tr>
</table>
</div>
</body>
</html>
报错现象;我用浏览器打开的时候,出现下面的页面脚本错误
Line:1
Char:190673
Code:0
Error:'this.element' 为空或不是对象
网址:http://localhost:8080/show/ReportServer?op=resource&resource=/com/fr/web/load.js
<%@page language="java" contentType="text/html; charset=GB2312" import="com.xscx.*,java.util.*" errorPage="xt_error.jsp"%>
<html>
<head>
<script type="text/javascript" src="/show/ReportServer?op=resource&resource=/com/fr/web/load.js"></script>
<Script Language="JavaScript">
function init(PicID) {
var $reportPane = $("#reportPane").PagePane(); // 取出实际的PagePane对象,PagePane用全局变量
alert(this.element); pagePane = $reportPane.data("PagePane");// james:get object of the pagepane
pagePane.load("/show/ReportServer?reportlet=/com/scbb/"+PicID+".cpt");
}
</Script>
</head>
<body onload="javascript:init('yyjmsjzy')">
<div id="reportPane" style="position:absolute;left:0px;top:0px; width:850px;height:600px;border-width:0">
<table border="0" width="844" height="30" cellspacing="0" cellpadding="0">
<tr>
<td background="IMG/right_extend.jpg"><font color="#707070" face="宋体" style="font-size:12px;"> 你现在的位置:>>集团内网 >> 应用查询数据</font>
</td>
</tr>
</table>
</div>
</body>
</html>
报错现象;我用浏览器打开的时候,出现下面的页面脚本错误
Line:1
Char:190673
Code:0
Error:'this.element' 为空或不是对象
网址:http://localhost:8080/show/ReportServer?op=resource&resource=/com/fr/web/load.js
解决方案 »
- 新手求学,求各位大哥大姐指教!关于字符的逐个判断问题!
- JSP标准动作元素<jsp:useBean>
- OGNL表达式问题......
- 这个java正则表达式\bint\b\\s*[i|j|k]\\s*[=]\\s*[0]\\s*[;]匹配int i = 0;有问题吗?
- lucene 问题,大虾过来看一下
- 问一个使用Hibernate时的一个错误
- struts中action的返回值问题,请教各位大侠
- 【关于 Tomcat 上下文相对路径 !!】
- 高分求助:怎样修改xml文件的一个元素的属性的值?
- SpringSecurity使用问题,登陆不能抛出自己定义的异常,用户不存在异常,用户尝试登陆次数过多,回到登陆之前访问的页面
- struts2 问题!
- 怎么我的Tomcat部署不了???急急急
上述用到的相关$是因为使用了一个软件finereport里的东西,所以才用的这玩意,说实话,我也不太清楚为何要用这个东西。
该软件使用自定义的DIV嵌入 才用到的
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title>FineReport Demo</title>
<link rel="stylesheet" type="text/css" href="/WebReport/ReportServer?op=resource&resource=/com/fr/web/core/css/page.css"/>
<link rel="stylesheet" type="text/css" href="/WebReport/ReportServer?op=resource&resource=/com/fr/web/load.css"/>
<script type="text/javascript" src="/WebReport/ReportServer?op=resource&resource=/com/fr/web/jquery.js"></script>
<script type="text/javascript" src="/WebReport/ReportServer?op=emb&resource=finereport.js"></script>
<script type="text/javascript">
$(function() {
var $reportPane = $("#reportPane").PagePane();
// 取出实际的PagePane对象,PagePane用全局变量
pagePane = $reportPane.data("PagePane");
pagePane.load("/WebReport/ReportServer?reportlet=/gettingstarted.cpt&country=China");
})
</script>
</head>
<body>
<div id="reportPane" style="width:100%;height:100%"></div> <!--报表div-->
</body>
</html>
我在<script type="text/javascript" src="/show/ReportServer?op=resource&resource=/com/fr/web/load.js"></script>
位置后,也将jquery。js给加进去了。可是还是出现那个问题。很是讨厌啊!请大侠给菜鸟指点一下!