Create the snippets content

This is a stub function either override getHtmlOutput() or override render()

@param \Zend_View_Abstract $view Just in case it is needed here
@return \MUtil_Html_HtmlInterface Something that can be rendered
353732
public function getHtmlOutput(\Zend_View_Abstract $view)
    {
        $html = $this->getHtmlSequence();

        $html->h3($this->_('System is in maintenance mode'));

        if ($this->token instanceof \Gems_Tracker_Token) {
            if ($this->token->isCompleted()) {
                if ($this->token->getNextUnansweredToken()) {
                    $html->pInfo()->strong($this->_('Your answers were processed correctly.'));
                    $html->pInfo($this->_(
                            'Unfortunately this system has just entered maintenance mode so you cannot continue.'
                            ));
                    $html->pInfo($this->_(
                            'Please try to continue at a later moment. Reuse your link or refresh this page.'
                            ));
                } else {
                    $html->pInfo($this->_('This system has just entered maintenance mode.'));
                    $html->pInfo($this->_(
                            'All your surveys have been processed correctly and there are no further questions.'
                            ));
                }
                return $html;
            }
        }

        $html->pInfo($this->_('Unfortunately you cannot answer surveys while the system is in maintenance mode.'));
        $html->pInfo($this->_('Please try again later.'));

        return $html;
    }
840207
public function getHtmlOutput(\Zend_View_Abstract $view)
    {
        $table = parent::getHtmlOutput($view);
        $table->getOnEmpty()->class = 'centerAlign';

        if (($this->containingId || $this->keyboard) && (! self::$keyboardUsed)) {
            // Assign keyboard tracking only once
            self::$keyboardUsed = true;

            $this->applyHtmlAttributes($table);

            // If we are already in a containing div it is simple
            if ($this->containingId) {
                return array($table, new \Gems_JQuery_TableRowKeySelector($this->containingId));
            }

            // Create a new containing div
            $div = \MUtil_Html::create()->div(array('id' => 'keys_target', 'class' => 'table-container'), $table);

            return array($div, new \Gems_JQuery_TableRowKeySelector($div));

        } else {
            return $table;
        }
    }
437170
public function render(string $view, array $variables = []): string
	{
		return $this->create($view, $variables)->render();
	}
553034
public function renderText($view, array $data = [])
    {
        $this->view->flushFinderCache();

        $contents = $this->view->replaceNamespace(
            'mail', $this->textComponentPaths()
        )->make($view, $data)->render();

        return new HtmlString(
            html_entity_decode(preg_replace("/[\r\n]{2,}/", "\n\n", $contents), ENT_QUOTES, 'UTF-8')
        );
    }
1276721
public function render(string $view, array $params = []): string
    {
        return $this->make($view, $params)->render();
    }
413145
public function getHtmlOutput(\Zend_View_Abstract $view)
    {
        $data = $this->getModel()->loadFirst();

        if ($data && isset($data['relpath'])) {
            $nameForUser = $data['relpath'];
        } else {
            $nameForUser = $this->request->getParam(\MUtil_Model::REQUEST_ID, $this->_('unknown'));
        }

        if (! ($data && file_exists($data['fullpath']))) {
            $this->addMessage(sprintf($this->_('The file "%s" does not exist on the server.'), $nameForUser));
            return \MUtil_Html::create('pInfo', sprintf($this->_('The file "%s" could not be imported.'), $nameForUser));
        }

        // \MUtil_Echo::track($data);
        return $this->_('Token');
    }
621082
public function createUiComponent(HtmlView $view) {
		if ($this->compact) {
			return $this->createCompactOutputUiComponent($view);
		}
		
		$targetRelationEntries = $this->toManyEiField->getValue();
		if (empty($targetRelationEntries)) return null;
		
		$targetEiuFrame = (new Eiu($this->targetEiFrame))->frame();
		
		$targetEiuEntries = array();
		foreach ($targetRelationEntries as $targetRelationEntry) {
			$targetEiEntry = null;
			if ($targetRelationEntry->hasEiEntry()) {
				$targetEiEntry = $targetRelationEntry->getEiEntry();
			} else {
				$targetEiEntry = $targetEiuFrame->entry($targetRelationEntry->getEiObject())->getEiEntry();
			}
			
			$targetEiuEntries[] = $targetEiuFrame->entry($targetEiEntry);
		}

		return $view->getImport('\rocket\impl\ei\component\prop\relation\view\embeddedOneToMany.html',
				array('eiuEntries' => $targetEiuEntries, 'reduced' => $this->reduced));
	}
1055705
public function render(View $view)
    {
        $this->eventDispatcher->dispatch(
            MVCEvents::PRE_CONTENT_VIEW,
            new PreContentViewEvent($view)
        );

        $templateIdentifier = $view->getTemplateIdentifier();
        if ($templateIdentifier instanceof Closure) {
            return $templateIdentifier($view->getParameters());
        }

        if ($view->getTemplateIdentifier() === null) {
            throw new NoViewTemplateException($view);
        }

        return $this->templateEngine->render(
            $view->getTemplateIdentifier(),
            $view->getParameters()
        );
    }
1139493
public function getHtmlOutput(\Zend_View_Abstract $view)
    {
        $html = $this->getHtmlSequence();

        $html->h3($this->_('Choose an organization'));

        $user = $this->loader->getCurrentUser();
        $url[$this->request->getControllerKey()] = 'organization';
        $url[$this->request->getActionKey()]     = 'change-ui';

        if ($orgs = $user->getRespondentOrganizations()) {
            $html->pInfo($this->_('This organization cannot have any respondents, please choose one that does:'));

            foreach ($orgs as $orgId => $name) {
                $url['org'] = $orgId;

                $html->pInfo()->actionLink($url, $name)->appendAttrib('class', 'larger');
            }
        } else {
            $html->pInfo($this->_('This organization cannot have any respondents.'));
        }

        return $html;
    }
1090638
public function render($view)
    {
        extract($this->attributes);

        ob_start();
        require $view;

        return $this->minify === true
            ? $this->min(ob_get_clean())
            : ob_get_clean();
    }
486423
public function create($view = null, array $data = [])
    {
        if (is_null($view)) {
            return $this;
        }

        return $this->render($view, $data, true)->content();
    }
631302
public function getHtmlOutput(\Zend_View_Abstract $view)
    {
        $html = $this->getHtmlSequence();

        $html->h3($this->_('Choose an organization'));

        $url[$this->request->getControllerKey()] = $this->request->getControllerName();
        $url[$this->request->getActionKey()]     = $this->action;

        if ($this->info) {
            $html->pInfo($this->info);
        }

        foreach ($this->orgs as $orgId => $name) {
            $url['org'] = $orgId;

            $html->pInfo()->actionLink($url, $name)->appendAttrib('class', 'larger');
        }

        return $html;
    }
866313
public function getHtmlOutput(\Zend_View_Abstract $view)
    {
        if ($this->roundId) {
            $htmlDiv   = \MUtil_Html::div();

            if ($this->showTitle) {
                $htmlDiv->h3(sprintf($this->_('%s round'), $this->trackEngine->getName()));
            }

            $table = parent::getHtmlOutput($view);
            $this->applyHtmlAttributes($table);

            // Make sure deactivated rounds are show as deleted
            foreach ($table->tbody() as $tr) {
                $skip = true;
                foreach ($tr as $td) {
                    if ($skip) {
                        $skip = false;
                    } else {
                        $td->appendAttrib('class', $table->getRepeater()->row_class);
                    }
                }
            }

            if ($this->showMenu) {
                $table->tfrow($this->getMenuList(), array('class' => 'centerAlign'));
            }

            $htmlDiv[] = $table;

            return $htmlDiv;

        } else {
            $this->addMessage($this->_('No round specified.'));
        }
    }
1173001
public function getHtmlOutput(\Zend_View_Abstract $view)
    {
        $seq = $this->getHtmlSequence();

        $seq->h2($this->_('Checks'));

        $seq->pInfo($this->_(
                'Check tokens for being answered or not, reruns survey and round event code on completed tokens and recalculates the start and end times of all tokens in tracks that have completed tokens.'
                ));
        $seq->pInfo($this->_(
                'Run this code when survey result fields, survey or round events or the event code has changed or after bulk changes in a survey source.'
                ));

        if ($this->itemDescription) {
            $seq->pInfo($this->itemDescription);
        }

        return $seq;
    }
438941
public function renderPage($view, $layout = null)
    {
        $event = new PageMenuContextualEvent($view);

        //Set currentView and dispatch victoire.on_render_page event with this currentView
        $pageRenderEvent = new PageRenderEvent($view);
        $this->eventDispatcher->dispatch('victoire.on_render_page', $pageRenderEvent);
        $this->currentViewHelper->setCurrentView($view);

        //Build WidgetMap
        $this->widgetMapBuilder->build($view, true);

        //Populate widgets with their data
        $this->widgetDataWarmer->warm($this->entityManager, $view);

        //Dispatch contextual event regarding page type
        if (in_array($view->getType(), ['business_page', 'virtual_business_page'])) {
            //Dispatch also an event with the Business entity name
            $eventName = 'victoire_core.page_menu.contextual';
            if (!$view->getId()) {
                $eventName = 'victoire_core.business_template_menu.contextual';
                $event = new PageMenuContextualEvent($view->getTemplate());
            }
            $this->eventDispatcher->dispatch($eventName, $event);
            $type = $view->getBusinessEntityId();
        } else {
            $type = $view->getType();
        }

        $eventName = 'victoire_core.'.$type.'_menu.contextual';
        $this->eventDispatcher->dispatch($eventName, $event);

        if (null === $layout) {
            //Determine which layout to use
            $layout = $this->guessBestLayoutForView($view);
        }
        $globalConfig = $this->entityManager->getRepository(GlobalConfig::class)->findLast() ?: new GlobalConfig();

        //Create the response
        $response = $this->container->get('templating')->renderResponse('VictoireCoreBundle:Layout:'.$layout.'.html.twig', [
            'globalConfig'                    => $globalConfig,
            'victoire_i18n_available_locales' => $this->availableLocales,
            'victoire_twig_responsive'        => $this->twigResponsive,
            'view'                            => $view,
        ]);

        return $response;
    }
138183
public function render(Zend_View_Interface $view = null)
	{
        $formTypes = array( // avaible form types of Twitter Bootstrap form (i.e. classes)
          'horizontal',
          'inline',
          'vertical',
          'search'
        );
        
        $set = false;
        
        foreach($formTypes as $type) {
            if($this->getAttrib($type)) {
                $this->addDecorator("Form", array("class" => "form-$type"));
                $set = true;
            } 
        }
        if(true !== $set) { // if neither type was set, we set the default vertical class
            $this->addDecorator("Form", array("class" => "form-vertical"));
        }

		return parent::render($view);
	}
1125999
public function createUiComponent(HtmlView $view) {
		if ($this->compact) {
			return $this->createCompactOutputUiComponent($view);
		}
		
		$targetUtils = (new Eiu($this->targetEiFrame))->frame();
		$panelEiPropPath = ContentItemsEiProp::getPanelEiPropPath();
		
		$groupedEiuEntries = array();
		foreach ($this->toManyEiField->getValue() as $targetRelationEntry) {
			$targetEiuEntry = null;
			if ($targetRelationEntry->hasEiEntry()) {
				$targetEiuEntry = $targetUtils->entry($targetRelationEntry->getEiEntry());
			} else {
				$targetEiuEntry = $targetUtils->entry($targetRelationEntry->getEiObject());
			}
			
			$panelName = (string) $targetEiuEntry->getValue($panelEiPropPath, true);
			if (!isset($groupedEiuEntries[$panelName])) {
				$groupedEiuEntries[$panelName] = array();
			}
			
			$groupedEiuEntries[$panelName][] = $targetEiuEntry;
		}
		
		return $view->getImport('\rocket\impl\ei\component\prop\ci\view\contentItems.html',
				array('panelLayout' => new PanelLayout($this->panelConfigs), 'groupedEiuEntries' => $groupedEiuEntries));
	}