var sUrl="test.htm";document.write('转到:<input type=text id=Page size=3 maxlength=10  value="3">');
document.write('<input type=button value=Go name=Go onclick="if(document.all[\'Page\'].value>0){window.location=\''+sUrl+'?page='+document.all['Page'].value+'\'}">');

解决方案 »

  1.   

    上面的还是不行,我要window.location动态获得Page.value,比如:Page里输入10,就可以赋值给window.location
      

  2.   

    var sUrl="test.htm";document.write('转到:<input type=text name=Page id=Page size=3 maxlength=10  value=3>');
    document.write('<input type=button value=Go name=Go onclick="if(document.all[\'Page\'].value>0){window.location=\''+sUrl+'?page=\'+document.all[\'Page\'].value;}">');
      

  3.   

    昨晚又花了半个小时,自己解决了。
    最后还是THANK 一下楼上的。