<a href="#" onclick="window.open('look.jsp? id=<%=Articles.getAuthor()%>')">查看</a></td>
 在look.jsp中, int id=Integer.parseInt(request.getParameter( "id")); out.println(id);
  点击查看, 输出结果总是:null。  请大家帮帮手!

解决方案 »

  1.   

    首先在页面中确认  <a   href="#"   onClick="window.open('look.jsp?id=<%=Articles.getAuthor()%','','300,   width=400,   height=500,   top=0,   left=0,   toolbar=no,   menubar=no,   scrollbars=yes,resizable=yes,location=no,   status=no');">备注</a>     
        
      然后在'look.jsp中request.getParameter("id"); 
      

  2.   

    <a href="#" onclick="window.open('look.jsp? id= <%=Articles.getAuthor()%>')">查看 </a> 
    你这个是超链接<a >参数可以直接到href里面传递...不用click试试...
      

  3.   

    你在点查看前查看一下网页的html源代码,看一下你的open函数里的url到底是什么样的
      

  4.   

    <a href="#" onclick="window.open('look.jsp? id= <%=Articles.getAuthor()%>')">查看 </a> </td> 
      先在你的本页,输出一下Articles.getAuthor()这个值是不是为空!!
       或者你进入这个页面的时候,查看下源代码,看下你的window.open里面的参数
       总感觉,你的这个Aticles没有实例化,直接拿来用的,最好把代码粘完全点,应该是你在这里就没有获得值呢!
      

  5.   


    <a href="#" onclick="window.open('look.jsp? id= <%=Articles.getAuthor()%>')">查看 </a>你再试试
      

  6.   

    更正:注意'look.jsp?id=<%=Articles.getAuthor()%>
    没空格.
      

  7.   


    int id=Integer.parseInt(request.getParameter( "id")); 
    //改成:
    int id=Integer.parseInt(request.getParameter( "id")+""); 
    //试试看
      

  8.   

    <a href="#" onclick="window.open('look.jsp? id= <%=Articles.getAuthor()%>')">查看 </a><a href="#" onclick="alert('<%=Articles.getAuthor()%>')">查看 </a>alert出来的结果是什么?