开发者

what is the specific difference between <html:submit tag and <input type="submit "?

what is the specific difference between <html:submit tag and <input type="submit "?

what is the advantage rather than开发者_如何学运维 we use <html:submit instead of <input type="submit"?


input type...

is a HTML tag and hence is interpreted at client side from browsers.

html:submit...

is a struts tag library, is evaluated server side and after evaluation it emits the corresponding HTML tag which is <input type....


Benefits of using 'html:' is that they work with the backing form bean.

Advantages (for other html: tags)

  • will populate with form variables set in the action
  • you will get errors on your jsp page when you try to use a form property that DNE.

As far as <html:submit goes, I can't think of any clear advantage of using it over <input type="submit" other than having all of your form tags "look the same".

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜