Initializes the widget.
This renders the form open tag.
769814
public function init()
	{
		if (!isset($this->htmlOptions['class']))
			$this->htmlOptions['class'] = 'form-' . $this->type;
		else
			$this->htmlOptions['class'] .= ' form-' . $this->type;

		if (!isset($this->inlineErrors))
			$this->inlineErrors = $this->type === self::TYPE_HORIZONTAL;

		if ($this->inlineErrors)
			$this->errorMessageCssClass = 'help-inline error';
		else
			$this->errorMessageCssClass = 'help-block error';

		parent::init();
	}
1177045
public function init() {

		parent::init();

		// Views
		$this->setViewPath( '@cmsgears/module-cms/admin/views/element' );

		// Config
		$this->type			= CmsGlobal::TYPE_ELEMENT;
		$this->templateType = CmsGlobal::TYPE_ELEMENT;
		$this->title		= 'Element';

		// Services
		$this->modelService = Yii::$app->factory->get( 'elementService' );
	}
555873
public function init()
    {
        parent::init();
        if (!isset($this->options['class']) || empty($this->options['class'])) {
            Html::addCssClass($this->options, ['widget' => 'navbar', 'navbar-expand-lg', 'navbar-light', 'bg-light']);
        } else {
            Html::addCssClass($this->options, ['widget' => 'navbar']);
        }
        $navOptions = $this->options;
        $navTag = ArrayHelper::remove($navOptions, 'tag', 'nav');
        $brand = '';
        if (!isset($this->innerContainerOptions['class'])) {
            Html::addCssClass($this->innerContainerOptions, 'container');
        }
        if (!isset($this->collapseOptions['id'])) {
            $this->collapseOptions['id'] = "{$this->options['id']}-collapse";
        }
        if ($this->brandImage !== false) {
            $this->brandLabel = Html::img($this->brandImage);
        }
        if ($this->brandLabel !== false) {
            Html::addCssClass($this->brandOptions, ['widget' => 'navbar-brand']);
            if ($this->brandUrl === null) {
                $brand = Html::tag('span', $this->brandLabel, $this->brandOptions);
            } else {
                $brand = Html::a(
                    $this->brandLabel,
                    $this->brandUrl === false ? Yii::$app->homeUrl : $this->brandUrl,
                    $this->brandOptions
                );
            }
        }
        Html::addCssClass($this->collapseOptions, ['collapse' => 'collapse', 'widget' => 'navbar-collapse']);
        $collapseOptions = $this->collapseOptions;
        $collapseTag = ArrayHelper::remove($collapseOptions, 'tag', 'div');

        echo Html::beginTag($navTag, $navOptions) . "\n";
        if ($this->renderInnerContainer) {
            echo Html::beginTag('div', $this->innerContainerOptions)."\n";
        }
        echo $brand . "\n";
        echo $this->renderToggleButton() . "\n";
        echo Html::beginTag($collapseTag, $collapseOptions) . "\n";
    }
558009
public function open()
    {
        parent::open();
        $this->tagFormats = [
            'emergency' => self::FG_BLACK . self::BG_RED . '|' . self::END,
            'alert' => self::FG_BLACK . self::BG_YELLOW . '|' . self::END,
            'critical' => self::FG_BLACK . self::BG_CYAN . '|' . self::END,
            'error' => self::FG_RED . '|' . self::END,
            'warning' => self::FG_YELLOW . '|' . self::END,
            'notice' => self::FG_WHITE . '|' . self::END,
            'info' => self::FG_GREEN . '|' . self::END,
            'debug' => self::FG_BLUE . '|' . self::END,
        ];
    }
1228890
public function init()
    {
        parent::init();

        if (empty($this->id)) {
            $this->id = $this->hasModel() ? Html::getInputId($this->model, $this->attribute) : $this->getId();
        }
        if (empty($this->name)) {
            $this->name = $this->hasModel() ? Html::getInputName($this->model, $this->attribute) : $this->id;
        }
        if (empty($this->value) && $this->hasModel() && $this->model->hasAttribute($this->attribute)) {
            $this->value = $this->model->getAttribute($this->attribute);
        }

        if(!$this->autoHeightEnable){
            if(empty($this->width)){
                $this->width = '100%';
            }
            if(empty($this->height)){
                $this->height = '350';
            }
        }

        $options = [
            'id' => $this->id,
            'style' => 'width:100%;height:350px'
        ];
        $this->options = array_merge($options,$this->options);

        $jsOptions = [
            'serverUrl' => Url::to(['ueditor','type'=>'ueditor']),
            'autoHeightEnable' => $this->autoHeightEnable,
            'autoFloatEnable' => true,
            'textarea'=>$this->name
        ];
        $this->jsOptions = array_merge($jsOptions,$this->jsOptions);
    }
193340
protected function InitForm()
    {
        $this->htmlCode = $this->LoadElement();
        $name = 'Code';
        $this->AddField(new Textarea($name, $this->htmlCode->GetCode()));
        $this->SetRequired($name);
        $this->AddCssClassField();
        $this->AddCssIDField();
        $this->AddSubmit();
    }
650961
public function init()
    {
        parent::init();
        echo Html::beginTag('div', $this->options) . "\n";

        //Fix for closing icon (x) not showing up in dialog
        $this->getView()->registerJs("
            if ($.fn.button) {
                var bootstrapButton = $.fn.button.noConflict(); 
                $.fn.bootstrapBtn = bootstrapButton;
            }",
            \yii\web\View::POS_READY
        );
    }
716960
protected function InitForm()
    {
        $this->select  = $this->LoadElement();
        
        $this->AddNameField();
        $this->AddValueField();
        $this->AddLabelField();
        $this->AddOptionsField();
        
        $this->AddDisableFrontendValidationField();
        $this->AddRequiredField();
        $this->AddTemplateField();
        $this->AddCssClassField();
        $this->AddCssIDField();
        $this->AddSubmit();
    }
535142
public function init()
	{
		if(isset($this->htmlOptions['id']))
			$id=$this->htmlOptions['id'];
		else
			$id=$this->htmlOptions['id']=$this->getId();
		if($this->url!==null)
			$this->url=CHtml::normalizeUrl($this->url);
		$cs=Yii::app()->getClientScript();
		$cs->registerCoreScript('treeview');
		$options=$this->getClientOptions();
		$options=$options===array()?'{}' : CJavaScript::encode($options);
		$cs->registerScript('Yii.CTreeView#'.$id,"jQuery(\"#{$id}\").treeview($options);");
		if($this->cssFile===null)
			$cs->registerCssFile($cs->getCoreScriptUrl().'/treeview/jquery.treeview.css');
		elseif($this->cssFile!==false)
			$cs->registerCssFile($this->cssFile);

		echo CHtml::tag('ul',$this->htmlOptions,false,false)."\n";
		echo self::saveDataAsHtml($this->data);
	}
641283
public function init()
  {
    if(!Yii::$app->user->isGuest)
    {
      if(Yii::$app->user->identity->isAdmin && $this->enableAdmin){
        Html::addCssClass($this->htmlOptions,'widgetadmin');      
        Draggable::begin();
      }
    }
    ob_start();
    ob_implicit_flush(false);
    
    $this->htmlOptions['id']=$this->getId();

    echo Html::beginTag($this->tagName,$this->htmlOptions)."\n";

    if(!Yii::$app->user->isGuest)
    {
      if(Yii::$app->user->identity->isAdmin && $this->enableAdmin){
        $this->renderToolbar();
      }
    }

    $this->renderDecoration();
    echo "<div class=\"{$this->contentCssClass}\">\n";

    $this->_beginTag=ob_get_contents();

    ob_clean();
    if(!Yii::$app->user->isGuest)
    {
      if(Yii::$app->user->identity->isAdmin && $this->enableAdmin){
        Draggable::end();
      }
    }
  }
172110
public function init() {
		if (!isset($this->options['id'])) {
			$this->options['id'] = $this->hasModel() ? Html::getInputId($this->model, $this->attribute) : $this->getId();
		}
		parent::init();
	}
775839
public function init()
    {
        parent::init();

        MainAsset::register($this->getView());
        InitAsset::register($this->getView());
        TooltipAsset::register($this->getView());

        echo Html::beginTag('body', ['class' => 'page-sidebar-closed-hide-logo page-container-bg-solid page-sidebar-closed-hide-logo page-boxed page-header-fixed page-footer-fixed']);
        $this->getView()->beginBody();
    }
1057693
public function init()
	{
		if (!isset($this->form))
			throw new CException(__CLASS__ . ': Failed to initialize widget! Form is not set.');

		if (!isset($this->model))
			throw new CException(__CLASS__ . ': Failed to initialize widget! Model is not set.');

		if (!isset($this->type))
			throw new CException(__CLASS__ . ': Failed to initialize widget! Input type is not set.');

		if ($this->type === self::TYPE_UNEDITABLE)
		{
			if (isset($this->htmlOptions['class']))
				$this->htmlOptions['class'] .= ' uneditable-input';
			else
				$this->htmlOptions['class'] = 'uneditable-input';
		}

		$this->processHtmlOptions();
	}
1084090
public function init()
    {
        $this->attachBehavior('TbWidget', new TbWidget);
        $this->resolveId();
        $route = $this->controller->getRoute();
        if ($this->stacked) {
            TbHtml::addCssClass('nav-stacked', $this->htmlOptions);
        }
        if (isset($this->scrollspy)) {
            if (is_string($this->scrollspy)) {
                $this->scrollspy = array('target' => $this->scrollspy);
            }
            $this->widget('\TbScrollspy', $this->scrollspy);
        }
        $this->items = $this->normalizeItems($this->items, $route, $hasActiveChild);
    }
1139025
public function init()
    {
        if ($this->runEvent) {
            $chain = new jsChain();
            $this->app->html->js(true, $chain->atkServerEvent(
                ['uri' => $this->getUrl()]
            ));
            $this->isRunning = true;
        }

        $this->_initialized = true;
    }
1272951
public function init()
	{
		parent::init();

		if($this->buttonType=='buttonset')
		{
			if(!isset($this->htmlOptions['id']))
				$this->htmlOptions['id']=$this->getId();

			echo CHtml::openTag($this->htmlTag,$this->htmlOptions);
		}
	}
126645
private void initialize() {
        this.setTitle(Constant.messages.getString("history.managetags.title"));
        this.setContentPane(getJPanel());
        if (Model.getSingleton().getOptionsParam().getViewParam().getWmUiHandlingOption() == 0) {
        	this.setSize(panelWidth, panelHeight);
        }
        this.addWindowListener(new java.awt.event.WindowAdapter() {   
        	@Override
        	public void windowOpened(java.awt.event.WindowEvent e) {    
        	} 

        	@Override
        	public void windowClosing(java.awt.event.WindowEvent e) {
        	}
        });

		pack();
	}