作者在 2017-02-28 12:02:15 发布以下内容
一、普通HTML页面代码
<html>
<head>
<script src='finereport.js'></script>
<script>
function cjkEncode(text) {
if (text == null) {
return "";
}
var newText = "";
for (var i = 0; i < text.length; i++) {
var code = text.charCodeAt (i);
if (code >= 128 || code == 91 || code == 93) { //91 is "[", 93 is "]".
newText += "[" + code.toString(16) + "]";
} else {
newText += text.charAt(i);
}
}
return newText;
}
function op(){
window.location=cjkEncode('http://localhost:8075/WebReport/ReportServer?reportlet=/培训/demo3.cpt&part=华东');
}
</script>
</head>
<body>
<button onclick='op()'>切换页面</button>
</body>
</html>
二、cpt中页面设置