Example #1
0
 /**
  * Ensure that the ID attribute is rendered and registers the javascript code
  * for initializing the active control.
  */
 protected function addAttributesToRender($writer)
 {
     parent::addAttributesToRender($writer);
     if ($this->getEnableClientScript() && $this->getAutoPostBack() && $this->getPage()->getClientSupportsJavaScript()) {
         $this->getActiveControl()->registerCallbackClientScript($this->getClientClassName(), $this->getPostBackOptions());
     }
 }