--原来html里面form地name属性现在变成啥了?答着有分!,系统编程教程的手机产品服务器,评测,行情 name=description>
新闻中心 | 电脑硬件 | 手机 | 数码相机 | 笔记本频道 | 服务器 | 美图频道 「总」 生活频道 渔鱼频道 电影频道 游戏频道 旅游频道 设为首页 | 收藏
网络学院
迷城学吧
硬件
手机
旅游
生活
渔鱼
美图
电影
游戏
  导航: 迷城学吧 · 系统编程教程 · Java语言 · JavaFAQ精华 · Java Struts  

Struts里面<html:form>--原来html里面form地name属性现在变成啥了?答着有分!

图文推荐
『Struts里面--原来html里面form地name属性现在变成啥了?答着有分!』可能有大量图片,显示会较慢,请等待图片下载完成
 
点击数: 更新时间:2006-7-14 

Struts的javadoc中有关于<html:form  name>的论述  
 
DEPRECATED:  The  bean  name  will  be  determined  from  the  corresponding  ActionMapping.    
 
Name  of  the  request  scope  or  session  scope  bean  (as  defined  by  the  scope  attribute)  whose  properties  will  be  used  to  populate  the  input  field  values.  If  no  such  bean  is  found,  a  new  bean  will  be  created  and  added  to  the  appropriate  scope,  using  the  Java  class  name  specified  by  the  type  attribute.  
 
If  this  attribute  is  not  specified,  the  name  of  the  bean  will  be  calculated  by  using  the  value  of  the  action  attribute  to  look  up  the  corresponding  ActionMapping  element,  from  which  the  specified  form  bean  name  will  be  selected.  
我不知道如何去理解这段文字,有想用到form的name属性,请问,该如何调用?  
---------------------------------------------------------------  
 
根据提交到的action调用哪个formbean来判断  
---------------------------------------------------------------  
 
form的name会自动赋值的  
---------------------------------------------------------------  
 
实现重置功能用javascript脚本语言,不要用类提供的方法。  
我想这是因为jsp容器在编译时不会自动生成这种类方法的脚本的缘故,也就是不支持把java语言转换成java脚本语言。好像也没有那个jsp容器提供了这个功能。  
---------------------------------------------------------------  
 
strut中form  的name属性一定要与type结合使用!!!!  
type为对应的ActionForm的完全限定类名!!!!!  
给分~~~~~~~~  
---------------------------------------------------------------  
 
html:form中没必要定义name。  
自己去查struts的帮助文档最清楚。  
 
struts的html:image会转化成<input  type="image"  >,这种形式的图片点击它就会执行submit,你可以试试html:img。  
 
---------------------------------------------------------------  
 
airlulu(airlulu)说得很清楚了!name  属性和type属性要以其使用,在struts理,<html:form  acton="a.do"  name  =  "form1"  type  =  "webapp.form.form1">    
或者你直接就写<html:form  acton="a.do">,然后自己去ie窗口里看他的source,他的名字是你在struts-config.xml定义的  
---------------------------------------------------------------  
 
与表单相关的ActionForm  bean的名称。如果没有设置这个属性,bean的名称将会从配置信息中获得  
---------------------------------------------------------------  
 
1  name与type必然的联系?建议你去看看<html:form>得原码,  
2  你是想通过点击图片执行reset操作吗?还是什么?如果是,那么reset可是public  方法,你想怎么用就怎么用吧,不过那时要进行一个提交操作的,建议使用javascript  
---------------------------------------------------------------  
 
<html:rest/>也可以实现,  
---------------------------------------------------------------  
 
name好象变成property了把

】【关闭窗口
  ·上一篇:
  ·下一篇:
Java Struts:相关文章
Java Struts点击榜
普通教程JBuilder8 + struts1.02 设计时
普通教程Struts1.02 Framework里面actio
普通教程做出html静态代码后,如果采用s
普通教程scope疑难
普通教程@@@@  bluesky35请进来接分,还
普通教程struts运用过程里面地疑难
普通教程怎么样控制struts去读哪个Appli
普通教程help?!#@%¥##struct1.0 里面
普通教程谁看了struct1.1里面struts-exa
普通教程为啥要运用structs框架完成mvc模
网友自拍|生活百味|历史图片|摄影世界|明星图片|体坛图库|美女图片|图片纪实|世界奇观
电脑硬件推荐文章
advertisement
关于站点 - 广告服务 - 联系我们 - 版权隐私 - 免责声明 - 合作伙伴 - 程序支持 - 网站地图 - 库库中文网 | 设为首页 | 本页加入收藏 返回顶部
网站文本地图
版权所有:迷城学吧 欢迎各种媒体转载我们的原创作品[转载请注明出处]
Copyright © 2005-2008 www.McXb.com online services. all rights reserved. 蜀ICP备09003996
Template designed by Monsi. Optimized for 1024x768 to Firefox and MS-IE6 7. Site powered by JoyON.
红盾Gov315
有一个迷样的城市
在每个人的内心深处
让我们探索发掘这古老的墓