<head>
<script>
function test()
{
...
}
</script>
</head><body>
<script>
<%For i = 1 to row_num%>
test()
<%Next%> 
</script>
</body>

解决方案 »

  1.   

    <%For i = 1 to row_num%>
    <script language="javascript">
    test();
    </script>
    <%Next%>
      

  2.   

    全是馊主意呵呵,只能在循环中构造对test的调用,在页面生成后再调用它。要真的在循环中调用不行。
      

  3.   

    上面两们大侠的方法都不行啊,秋水无恨的只能显示多个"test()"文本,人间兵器的到是可以,不过i变量却不能传进去,像下面这样:<head>
    <script>
    function test(x)
    {
    ...
    }
    </script>
    </head><body>
    <script>
    <%For i = 1 to row_num%>
    <script language="javascript">
    test(i);
    </script>
    <%Next%> 
    </script>
    </body>