1: <?php
2:
3: namespace webfilesframework\io\form\formItem;
4:
5: 6: 7: 8: 9: 10:
11: class MTextfieldFormItem extends MAbstractFormItem
12: {
13:
14: public function init()
15: {
16: $this->code = "<div style=\"margin-top:4px;\">" .
17: "<label style=\"width:" . $this->getLabelWidth() . "px;display:block;float:left;\">";
18: if (!empty($this->localizedName)) {
19: $this->code .= $this->localizedName;
20: } else {
21: $this->code .= $this->name;
22: }
23: $this->code .= "</label>" .
24: "<input name=\"" . $this->name . "\"
25: value=\"" . $this->value . "\"
26: style=\"width: 438px;\"
27: dojoType=\"dijit.form.TextBox\"
28: required=\"false\"
29: invalidmessage=\"Required field\">
30: </div>";
31: }
32:
33: }
34: