我无法让Internet Explorer正常刷新我的ColdFusion页面 [英] I can't get Internet Explorer to properley refresh my ColdFusion page
本文介绍了我无法让Internet Explorer正常刷新我的ColdFusion页面的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我做了这个漂亮的小表:
I have made this nice little table:
testPage.cfm:
testPage.cfm:
<html>
<head>
<title>Test Page</title>
<style>
.blue{
background:#66CCFF;
padding: 1px 20px;
}
.red{
background:red;
padding: 1px 20px;
}
.blank{
background:#FFF;
padding: 1px 20px;
}
</style>
</head>
<body>
<cfform>
<cfinput type="checkbox" name="filters" value="blue" checked="yes"> Blue
<br />
<br />
<cfinput type="checkbox" name="filters" value="red" checked="yes"> Red
</cfform>
<cfdiv id="content" bind="cfc:TestCFC.displayTable({filters})"></cfdiv>
</body>
</html>
TestCFC.cfc:
TestCFC.cfc:
<cfcomponent>
<cfscript>
remote function displayTable(filters){
var html = "";
var data = ArrayNew(1);
data[1] = 1;
data[2] = 2;
data[3] = 3;
data[4] = 4;
html = html & "<table>";
for(row = 0; row < 4; row++){
html = html & "<tr>";
for(column = 0; column < 2; column++){
html = html & '<td class="' & getCSS(data[row + 1], filters) & '">' & data[row + 1] & '</td>';
}
html = html & "</tr>";
}
return html;
}
private function getCSS(value, filters){
if(isIn("blue", filters) and value LTE 2)
return "blue";
else if(isIn("red", filters) and value GTE 3)
return "red";
else
return "blank";
}
private function isIn(item, list){
var array = ListToArray(list);
for(ndx = 1; ndx LTE ArrayLen(array); ndx += 1)
if(array[ndx] EQ item)
return True;
return False;
}
</cfscript>
</cfcomponent>
这在FireFox中可以正常工作,但在Internet Explorer中却不是那么好(提示:在IE中,您必须在屏幕上某处点击一个额外的时间)
this works fine in FireFox but not so well in Internet Explorer, (hint: to get it to respond in IE you have to click an additional time somewhere on the screen)
IE版本7.0.6002.18005
ColdFusion 9
IE version 7.0.6002.18005 ColdFusion 9
推荐答案
我发现了我自己的答案。更改
I found my own answer. Change
<cfdiv id="content" bind="cfc:TestCFC.displayTable({filters})"></cfdiv>
到
<cfdiv id="content" bind="cfc:TestCFC.displayTable(filters={filters@click})"></cfdiv>
这里是 post ,让我指出正确的方向。
here's the post that got me pointed in the right direction.
这篇关于我无法让Internet Explorer正常刷新我的ColdFusion页面的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文