Nette\Forms\Controls\BaseControl::getControlPrototype PHP Method

getControlPrototype() public method

Returns control's HTML element template.
public getControlPrototype ( ) : Nette\Utils\Html
return Nette\Utils\Html
    public function getControlPrototype()
    {
        return $this->control;
    }

Usage Example

コード例 #1
0
ファイル: DependencyHelper.php プロジェクト: mike227/n-forms
 public function createButton()
 {
     if ($this->button) {
         return FALSE;
     }
     /** @var Nette\Forms\Container $container */
     $container = $this->control->lookup('Nette\\Forms\\Container');
     $name = $this->control->getName() . self::$buttonSuffix;
     $this->button = new SubmitButton("Apply");
     $this->button->setValidationScope(false);
     $container->addComponent($this->button, $name);
     $this->control->getControlPrototype()->addAttributes(array('data-apply-button' => $this->button->getHtmlId()));
     return TRUE;
 }
All Usage Examples Of Nette\Forms\Controls\BaseControl::getControlPrototype