for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace hemio\form\template;
use hemio\html;
use hemio\form\Abstract_;
use hemio\html\Interface_\Submittable;
/**
*
*/
class FormLineP extends Abstract_\TemplateFormField
{
public function __construct()
$this['P'] = new html\P;
$this['P']['LABEL'] = new html\Label();
$this->setPostInitHook(function ($template) {
$template
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.
});
}
public function setPostInitHook(callable $function)
$this->postInitHook = $function;
public function init(Abstract_\FormField $field, Submittable $control)
$this->setField($field);
$this->setControl($control);
$this['P']['LABEL']->addChild($field->getHtmlTitle());
$this['P']['LABEL']->setAttribute('for', $this->field->getHtmlId());
$control->setAttribute('name', $field->getHtmlName());
$control->setId($field->getHtmlId());
$this['P']['CONTROL'] = $control;
$hook = $this->postInitHook;
$hook($this);
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.