Conditions | 4 |
Paths | 4 |
Total Lines | 15 |
Code Lines | 10 |
Lines | 4 |
Ratio | 26.67 % |
Changes | 0 |
1 | <?php namespace XoopsModules\Extcal\Form; |
||
42 | public function render() |
||
43 | { |
||
44 | $ret = ''; |
||
45 | View Code Duplication | if (count($this->getOptions()) > 1 && '[]' !== substr($this->getName(), -2, 2)) { |
|
46 | $newname = $this->getName() . '[]'; |
||
47 | $this->setName($newname); |
||
48 | } |
||
49 | foreach ($this->getOptions() as $value => $name) { |
||
50 | $ret .= "<input type='checkbox' name='" . $this->getName() . "' value='" . $value . "'"; |
||
51 | $ret .= ' checked'; |
||
52 | $ret .= $this->getExtra() . '>' . $name . "<br>\n"; |
||
53 | } |
||
54 | |||
55 | return $ret; |
||
56 | } |
||
57 | } |
||
58 |
Adding a
@return
annotation to a constructor is not recommended, since a constructor does not have a meaningful return value.Please refer to the PHP core documentation on constructors.