日期:2014-05-20  浏览次数:20640 次

在xslt文件中包含js代码时,小于号不被识别的问题
JScript code
<script language="javascript">
                    var checks = document.getElementsByName("urlcheckbox");
                    function checkOthers(){
                          var b = false;
                          for(var i = 0; i < checks.length; i++) {
                            if(checks[i].checked == false) {
                              checks[i].disabled == true;
                            }
                          }
                    }
                </script>

我这么写的话,程序报错:Multiple annotations found at this line:
- Missing end tag "checks.length"
- Element type "checks.length" must be followed by either attribute specifications, ">" or "/
>".
- Tag missing closing bracket '>'

就是因为i<checks.length 这里的小于号在xslt文件里不被识别,请问应该用什么替换这个小于号呢?

------解决方案--------------------
\< 可以吗?

呵呵!我想不应该是 &lt;