设置隐参name="test1" property="A",试试
不过建议你的submit最好调用后台.java来实现

解决方案 »

  1.   

    直接用java代码操作吧   check(' <%= ((具体类名)request.getAttribute(test1)).getA()%>')    实际是什么类就转成什么类然后 A属性的值
      

  2.   

    楼上的,我试验了一下,传送过去的是<%= ((具体类名)request.getAttribute(test1)).getA()%>这一串字符串,并不是值;这种写法也不行(去掉两头的'),check(<%= ((具体类名)request.getAttribute(test1)).getA()%>) ,不过还是谢谢你的热心关注。至于沙发说的“隐参name="test1" property="A",调用后台.java来实现
    ”我没明白是什么意思。不过也要谢谢你,提供了新的思路。
      

  3.   

    樓主,<bean:write>標簽需要結束符</bean:write>的呀.你試試這樣寫看行不行:
    onclick="return check('<bean:write name="test1" property="A"/>');"
      

  4.   

    <html:submit name="搜索" onclick="return check('${test1.A}');"/>
    这样呢??
      

  5.   

    这样应该行
    <input type="submit" name="搜索" onclick="return check(<bean:write name="test1" property="A">);"/>
      

  6.   

    首先谢谢大家,上面那么多朋友的发言中,只有楼上leojay1(绯村剑心)说的,该城静态标签的方法可以。这样应该行
    <input type="submit" name="搜索" onclick="return check(<bean:write name="test1" property="A">);"/>但是我想问一下,struts中html标签之能掉用固定值吗?无法调用jsp中的变量吗?这种问题只有用静态input标签可以借决马?