开发者

Different Ways of creating Buttons in DOJO Framework

Hi , i found these two ways for creating Button in DOJO Framework开发者_如何学Go

<input id="cb" dojotype="dijit.form.Button" name="developer" type="Button" />

<button dojoType="Button" widgetId="helloButton" onClick="helloPressed();">Hello World!</button>

Please tell me if there is any difference between these two ways of creating buttons in DOJO ??


From Dojo's dijit.form.Button documentation, the difference is in the html tag underlying dojo's widget. Here <button> vs. <input type="button" />. Which to use? there is an interesting discussion about html button vs html input with type=button.

The main difference is that the second choice lets you write html content between tags.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜