Log updates
[beagleboard.org.git] / code / .docs / prototype_Global / function_helma.Html.prototype.button.html
blob80324b78ffa9e36079c38eaf96f7ea5a26b5b8bc
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
2 <html>
4 <head>
5 <title></title>
6 <style type="text/css">
8 body, p, td, th, li {
9 font-family: verdana, sans-serif;
10 font-size: 10pt;
13 big.top {
14 font-size: 18pt;
15 font-weight: bold;
18 big {
19 font-size: 13pt;
20 font-weight: bold;
23 a {
24 font-weight:bold;
25 color: #cc3333;
26 text-decoration:none;
28 a:hover {
29 text-decoration:underline;
32 .navig {
33 font-size: 9px;
34 text-decoration: none;
35 font-weight:normal;
38 li {
39 padding-bottom: 5px;
43 .mainbox {
44 border-color:#999999;
45 padding-top:5px;
46 padding-bottom:5px;
47 border-bottom-width:1px;
48 border-bottom-style:dotted;
51 .headline {
52 font-weight:bold;
53 background:#dfdfdf;
54 border-color:#999999;
55 padding-top:5px;
56 padding-bottom:5px;
59 </style>
60 </head>
62 <body>
64 <table width="90%" border="0" cellspacing="1" cellpadding="5">
65 <tr>
66 <td class="headline">
67 <big><tt>Global.helma.Html.prototype.button&nbsp;(param)</tt></big><br>
68 </td>
69 </tr>
71 <tr>
72 <td class="mainbox">
73 Renders an x/html button input tag <br><br>
75 <ul>
76 <li><b>Parameter</b> <code>{Object}</code>:<br/>
77 param An object containing the tag attributes
83 </ul>
84 </td>
85 </tr>
86 </table>
88 <table width="90%" border="0" cellspacing="1" cellpadding="5">
89 <tr>
90 <td>Sourcecode in /root/helma-1.6.1/modules/helma/Html.js:
91 <pre><font color="#aaaaaa">426:</font> helma.Html.prototype.button = function(param) {
92 <font color="#aaaaaa">427:</font> if (!param) {
93 <font color="#aaaaaa">428:</font> res.write(<font color="#9999aa">&quot;[Html.button: insufficient arguments]&quot;</font>);
94 <font color="#aaaaaa">429:</font> return;
95 <font color="#aaaaaa">430:</font> }
96 <font color="#aaaaaa">431:</font> var attr = Object.prototype.reduce.call(param);
97 <font color="#aaaaaa">432:</font> attr.type = <font color="#9999aa">&quot;button&quot;</font>;
98 <font color="#aaaaaa">433:</font> if (!attr.name)
99 <font color="#aaaaaa">434:</font> attr.name = attr.type;
100 <font color="#aaaaaa">435:</font> attr.value = (attr.value != null) ? encodeForm(attr.value) : attr.type;
101 <font color="#aaaaaa">436:</font> this.tag(<font color="#9999aa">&quot;input&quot;</font>, attr);
102 <font color="#aaaaaa">437:</font> return;
103 <font color="#aaaaaa">438:</font> }
104 </pre>
105 </td>
106 </tr>
108 </table>
114 </body>
115 </html>