Renders a page for the module.

@return void
184741
public function dispatch()
  {
    $moduleName = $this->app->getModuleName();
    $actionName = $this->app->getActionName();
    $layoutFile = $moduleName . ($actionName != "index" ? "_" . $actionName : "") . ".tpl.php";

    $this->tpl->render($layoutFile);
  }
1216701
public function render()
    {
        Merchant::script($this->script);

        return view($this->getView(), $this->variables());
    }
711612
function Render()
    {
        if (!self::Guard()->Allow(Action::Read(), $this->content))
        {
            return '';
        }
        ContentTranslator::Singleton()->SetContent($this->content);
        $module = ClassFinder::CreateFrontendModule($this->content->GetType());
        $module->SetTreeItem($this->tree, $this->item);
        return $module->Render();
    }
814648
public function render()
    {
        $template_name = $this->base->load->template[0];

        $template_file = configItem('site')['templatedir'] . $template_name . '.tpl';

        if (file_exists($template_file)) {

            $template = $this->twig->loadTemplate($template_name . '.tpl');

            $template_data = array();

            if (isset($this->base->load->template[1]) && is_array($this->base->load->template[1]))
            {
                $template_data = $this->base->load->template[1];

                foreach($template_data as $key => $value)
                {
                    $file = configItem('site')['viewdir'] . $value;

                    if (file_exists($file) && is_file($file))
                    {
                        $template_data[$key] = $this->base->getFileOutput($file);
                        $this->base->logger->info("View parsed - $file");

                    }
                }
            }
            $this->template_markup = $template->render($template_data);

            if(sizeof($this->injections) > 0)
            {
                $this->_applyInjections();
            }
            echo $this->template_markup;

        } else {
            //log error
        }
    }
948092
public function render(){
        $this->event->trigger("onInit", $this);
        EventMaster::trigger_static("connectorInit",$this);

        if (!$this->as_string)
            $this->parse_request();
        $this->set_relation();

        if ($this->live_update !== false && $this->updating!==false) {
                $this->live_update->get_updates();
        } else {
            if ($this->editing){
                if (($this->action_mode == "links") && isset($this->options["links"])) {
                    $this->options["links"]->save();
                } else {
                    $dp = new $this->names["data_class"]($this,$this->config,$this->request);
                    $dp->process($this->config,$this->request);
                }
            } else {
                if (!$this->access->check("read")){
                    LogMaster::log("Access control: read operation blocked");
                    echo "Access denied";
                    die();
                }
                $wrap = new SortInterface($this->request);
                $this->apply_sorts($wrap);
                $this->event->trigger("beforeSort",$wrap);
                $wrap->store();

                $wrap = new FilterInterface($this->request);
                $this->apply_filters($wrap);
                $this->event->trigger("beforeFilter",$wrap);
                $wrap->store();

                if ($this->model && method_exists($this->model, "get")){
                    $this->sql = new ArrayDBDataWrapper();
                    $result = new ArrayQueryWrapper(call_user_func(array($this->model, "get"), $this->request));
                    $out = $this->output_as_xml($result);
                } else {
                    $out = $this->output_as_xml($this->get_resource());

                    if ($out !== null) return $out;
                }

            }
        }
        $this->end_run();
    }
772813
public function render () {
        $content = $this->renderToString();

        if ($this->redirect !== null) {
            header("Location: ".$this->redirect);
            session_write_close();
            exit();
            return;
        }

        // Headers are also calculated in render to string
        if($this->isJsonResponse()) {
            header("Content-type: application/json;");
        }


        echo $content;
        exit ();
    }
309036
public function render()
    {
        parent::render();
        $myUtilsServer = \OxidEsales\Eshop\Core\Registry::getUtilsServer();

        $sItem = \OxidEsales\Eshop\Core\Registry::getConfig()->getRequestParameter("item");
        $sItem = $sItem ? basename($sItem) : false;
        if (!$sItem) {
            $sItem = "nav_frame.tpl";
            $aFavorites = \OxidEsales\Eshop\Core\Registry::getConfig()->getRequestParameter("favorites");
            if (is_array($aFavorites)) {
                $myUtilsServer->setOxCookie('oxidadminfavorites', implode('|', $aFavorites));
            }
        } else {
            $oNavTree = $this->getNavigation();

            // set menu structure
            $this->_aViewData["menustructure"] = $oNavTree->getDomXml()->documentElement->childNodes;

            // version patch string
            $this->_aViewData["sVersion"] = $this->_sShopVersion;

            //checking requirements if this is not nav frame reload
            if (!\OxidEsales\Eshop\Core\Registry::getConfig()->getRequestParameter("navReload")) {
                // #661 execute stuff we run each time when we start admin once
                if ('home.tpl' == $sItem) {
                    $this->_aViewData['aMessage'] = $this->_doStartUpChecks();
                }
            } else {
                //removing reload param to force requirements checking next time
                \OxidEsales\Eshop\Core\Registry::getSession()->deleteVariable("navReload");
            }

            // favorite navigation
            $aFavorites = explode('|', $myUtilsServer->getOxCookie('oxidadminfavorites'));

            if (is_array($aFavorites) && count($aFavorites)) {
                $this->_aViewData["menufavorites"] = $oNavTree->getListNodes($aFavorites);
                $this->_aViewData["aFavorites"] = $aFavorites;
            }

            // history navigation
            $aHistory = explode('|', $myUtilsServer->getOxCookie('oxidadminhistory'));
            if (is_array($aHistory) && count($aHistory)) {
                $this->_aViewData["menuhistory"] = $oNavTree->getListNodes($aHistory);
            }

            // open history node ?
            $this->_aViewData["blOpenHistory"] = \OxidEsales\Eshop\Core\Registry::getConfig()->getRequestParameter('openHistory');
        }

        $blisMallAdmin = \OxidEsales\Eshop\Core\Registry::getSession()->getVariable('malladmin');
        $oShoplist = oxNew(\OxidEsales\Eshop\Application\Model\ShopList::class);
        if (!$blisMallAdmin) {
            // we only allow to see our shop
            $iShopId = \OxidEsales\Eshop\Core\Registry::getSession()->getVariable("actshop");
            $oShop = oxNew(\OxidEsales\Eshop\Application\Model\Shop::class);
            $oShop->load($iShopId);
            $oShoplist->add($oShop);
        } else {
            $oShoplist->getIdTitleList();
        }

        $this->_aViewData['shoplist'] = $oShoplist;
        return $sItem;
    }
861079
public function render()
    {
        if ($this->report->fireEvent("OnBeforeWidgetRender", $this)) {
            $type=str_replace('\\', '/', get_class($this));
            echo "<krwidget widget-name='$this->name' widget-type='$type'"
                .($this->themeCssClass?" class='$this->themeCssClass'":"").">";
            $this->onRender();
            echo "</krwidget>";
        }
        $this->report->fireEvent("OnWidgetRender", $this);
    }
1074543
public function render()
    {
        parent::render();

        // malladmin stuff
        $oAuthUser = oxNew(\OxidEsales\Eshop\Application\Model\User::class);
        $oAuthUser->loadAdminUser();
        $blisMallAdmin = $oAuthUser->oxuser__oxrights->value == "malladmin";

        // User rights
        $aUserRights = [];
        $oLang = \OxidEsales\Eshop\Core\Registry::getLang();
        $iTplLang = $oLang->getTplLanguage();

        $iPos = count($aUserRights);
        $aUserRights[$iPos] = new stdClass();
        $aUserRights[$iPos]->name = $oLang->translateString("user", $iTplLang);
        $aUserRights[$iPos]->id = "user";

        if ($blisMallAdmin) {
            $iPos = count($aUserRights);
            $aUserRights[$iPos] = new stdClass();
            $aUserRights[$iPos]->id = "malladmin";
            $aUserRights[$iPos]->name = $oLang->translateString("Admin", $iTplLang);
        }

        $aUserRights = $this->calculateAdditionalRights($aUserRights);

        $soxId = $this->_aViewData["oxid"] = $this->getEditObjectId();
        if (isset($soxId) && $soxId != "-1") {
            // load object
            $oUser = oxNew(\OxidEsales\Eshop\Application\Model\User::class);
            $oUser->load($soxId);
            $this->_aViewData["edit"] = $oUser;

            if (!($oUser->oxuser__oxrights->value == "malladmin" && !$blisMallAdmin)) {
                // generate selected right
                reset($aUserRights);
                foreach ($aUserRights as $val) {
                    if ($val->id == $oUser->oxuser__oxrights->value) {
                        $val->selected = 1;
                        break;
                    }
                }
            }
        }

        // passing country list
        $oCountryList = oxNew(\OxidEsales\Eshop\Application\Model\CountryList::class);
        $oCountryList->loadActiveCountries($oLang->getObjectTplLanguage());

        $this->_aViewData["countrylist"] = $oCountryList;

        $this->_aViewData["rights"] = $aUserRights;

        if ($this->_sSaveError) {
            $this->_aViewData["sSaveError"] = $this->_sSaveError;
        }

        if (!$this->_allowAdminEdit($soxId)) {
            $this->_aViewData['readonly'] = true;
        }
        if (\OxidEsales\Eshop\Core\Registry::getConfig()->getRequestParameter("aoc")) {
            $oUserMainAjax = oxNew(\OxidEsales\Eshop\Application\Controller\Admin\UserMainAjax::class);
            $this->_aViewData['oxajax'] = $oUserMainAjax->getColumns();

            return "popups/user_main.tpl";
        }

        return "user_main.tpl";
    }
608655
public function render()
	{
		$this->latte->setLoader($this->file ? new FileLoader() : new StringLoader());
		$this->latte->render($this->file ?: $this->source, $this->params);
	}
224163
public function render() {
		$output = null;
		if ( $this->child_count() > 0 ) {
			$output .= '<div id="panel-' . esc_attr( $this->id() ) . '" class="uix-' . esc_attr( $this->type ) . '-inside ' . esc_attr( $this->wrapper_class_names() ) . '">';
			$output .= $this->label() . $this->description() . $this->navigation() . $this->panel_section();
			$output .= '</div>';
		} else {
			$output .= $this->panel_section();
		}
		$output .= $this->render_template();

		return $output;
	}
861912
public function render()
    {
        parent::render();

        // remove itm from list
        unset($this->_aViewData["sumtype"][2]);

        $soxId = $this->_aViewData["oxid"] = $this->getEditObjectId();
        $oPayment = oxNew(\OxidEsales\Eshop\Application\Model\Payment::class);

        if (isset($soxId) && $soxId != "-1") {
            $oPayment->loadInLang($this->_iEditLang, $soxId);

            $oOtherLang = $oPayment->getAvailableInLangs();
            if (!isset($oOtherLang[$this->_iEditLang])) {
                // echo "language entry doesn't exist! using: ".key($oOtherLang);
                $oPayment->loadInLang(key($oOtherLang), $soxId);
            }
            $this->_aViewData["edit"] = $oPayment;

            // remove already created languages
            $aLang = array_diff(\OxidEsales\Eshop\Core\Registry::getLang()->getLanguageNames(), $oOtherLang);
            if (count($aLang)) {
                $this->_aViewData["posslang"] = $aLang;
            }

            foreach ($oOtherLang as $id => $language) {
                $oLang = new stdClass();
                $oLang->sLangDesc = $language;
                $oLang->selected = ($id == $this->_iEditLang);
                $this->_aViewData["otherlang"][$id] = clone $oLang;
            }

            // #708
            $this->_aViewData['aFieldNames'] = \OxidEsales\Eshop\Core\Registry::getUtils()->assignValuesFromText($oPayment->oxpayments__oxvaldesc->value);
        }

        if (\OxidEsales\Eshop\Core\Registry::getConfig()->getRequestParameter("aoc")) {
            $oPaymentMainAjax = oxNew(\OxidEsales\Eshop\Application\Controller\Admin\PaymentMainAjax::class);
            $this->_aViewData['oxajax'] = $oPaymentMainAjax->getColumns();

            return "popups/payment_main.tpl";
        }

        $this->_aViewData["editor"] = $this->_generateTextEditor("100%", 300, $oPayment, "oxpayments__oxlongdesc");

        return "payment_main.tpl";
    }
1299231
public function render() {
        $tplInfo = pathinfo($this->tpl);
        if (!isset($tplInfo['extension'])) {
            $tplInfo['extension'] = 'tpl';
            $this->tpl            .= '.tpl';
        }
        if (defined('LANGUAGE')) {
            $lang_tpl = $tplInfo['dirname'] . DS . $tplInfo['filename'] . '_' . LANGUAGE . '.' . $tplInfo['extension'];
            $tpl      = THEME_PATH . $lang_tpl;
            if (is_file($tpl)) {
                $this->tpl = $lang_tpl;
            } else if (($pos = strpos(LANGUAGE, '-', 1))) {
                $lang_tpl = $tplInfo['dirname'] . DS . $tplInfo['filename'] . '_' . substr(LANGUAGE, 0, $pos) . '.' . $tplInfo['extension'];
                $tpl      = THEME_PATH . $lang_tpl;
                if (is_file($tpl)) {
                    $this->tpl = $lang_tpl;
                }
            }
        }
        $tpl    = THEME_PATH . $this->tpl;
        $devMod = APP_MODE != 'pro';
        if (is_file($tpl)) {
            $this->__smarty = new \Smarty ();
            $tpl            = str_replace(DS, '/', $this->tpl);
            $tpl            = explode('/', $tpl);
            $sub            = implode(DS, array_slice($tpl, 0, -1));

            $this->__smarty->setTemplateDir(THEME_PATH);
            $this->__smarty->setCompileDir(TMP_PATH . 'themes_c' . DS . $sub);
            $this->__smarty->setCacheDir(TMP_PATH . 'themes_cache' . DS . $sub);
            $this->__smarty->setDebugTemplate(SMARTY_DIR . 'debug.tpl');
            fire('init_smarty_engine', $this->__smarty);
            fire('init_template_smarty_engine', $this->__smarty);
            $this->__smarty->compile_check = 1;
            if ($devMod) {
                $this->__smarty->caching = false;
            }
            $this->__smarty->error_reporting = defined('KS_ERROR_REPORT_LEVEL') ? KS_ERROR_REPORT_LEVEL : 0;
        } else {
            throw new \Exception(__('The template %s is not found', THEME_DIR . '/' . $this->tpl));
        }
        $this->__smarty->assign($this->data);
        $this->__smarty->assign('_css_files', $this->sytles);
        $this->__smarty->assign('_js_files', $this->scripts);
        $this->__smarty->assign('_current_template_file', $this->tpl);
        @ob_start();
        if ($this->__mustache) {
            $filter  = new MustacheFilter();
            $filters = apply_filter('smarty\getFilters', ['pre' => [[$filter, 'pre']], 'post' => [[$filter, 'post']]]);
        } else {
            $filters = apply_filter('smarty\getFilters', ['pre' => [], 'post' => []]);
        }

        if ($filters) {
            foreach ($filters as $type => $cbs) {
                foreach ($cbs as $cb) {
                    $this->__smarty->registerFilter($type, $cb);
                }
            }
        }
        $this->__smarty->display($this->tpl);
        $content = @ob_get_clean();

        if ($devMod && $content) {
            $debugArg = App::cfg('debugArg', '');
            if ($debugArg) {
                $debugArg    = json_encode($this->data, JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE);
                $debugString = '<script>console.log([\'pageData\',' . $debugArg . '])</script>';
                $content     = str_replace('<!--pageEnd-->', $debugString, $content);
            }
        }

        return $content;
    }
165756
public function render()
	{
		$paginator = $this->getPaginator();
		$page = $paginator->page;
		if ($paginator->pageCount < 2) {
			$steps = array($page);
		} else {
			$arr = range(max($paginator->firstPage, $page - 3), min($paginator->lastPage, $page + 3));
			if ($this->countBlocks) {
				$quotient = ($paginator->pageCount - 1) / $this->countBlocks;
				for ($i = 0; $i <= $this->countBlocks; $i++) {
					$arr[] = round($quotient * $i) + $paginator->firstPage;
				}
			}
			sort($arr);
			$steps = array_values(array_unique($arr));
		}

		$this->template->steps = $steps;
		$this->template->paginator = $paginator;
		$this->template->isAjax = $this->isAjax;
		$this->template->handle = 'showPage!';

		$this->template->setFile($this->getTemplateFile());
		$this->template->render();
	}
494363
public function render()
    {
        $text = $this->generator->generate();
        $answer = $this->generator->getAnswer();

        $this->storage->set($answer);
        $this->imageGenerator->render($text);
    }
473867
public function render()
    {
        if (!$this->visible) {
            return;
        }

        if ($this->sensitive) {
            $anchor = new SwatHtmlTag('a');

            if ($this->link_value === null) {
                $anchor->href = $this->link;
            } elseif (is_array($this->link_value)) {
                $anchor->href = vsprintf($this->link, $this->link_value);
            } else {
                $anchor->href = sprintf($this->link, $this->link_value);
            }

            $anchor->open();
        }

        parent::render();

        if ($this->sensitive) {
            $anchor->close();
        }
    }
74848
protected function doProcess(): void
    {
        $module = Request::getModule();
        $controller = Request::getController();
        $params = Request::getParams();

        try {
            // try to dispatch controller
            $result = $this->dispatch($module, $controller, $params);
        } catch (ForbiddenException $e) {
            // dispatch default error controller
            $result = $this->forbidden($e);
        } catch (RedirectException $e) {
            // should return `null` for disable output and setup redirect headers
            $result = $this->redirect($e);
        } catch (\Exception $e) {
            // dispatch default error controller
            $result = $this->error($e);
        }

        // setup layout, if needed
        if ($this->useLayout()) {
            // render view to layout
            // needed for headScript and headStyle helpers
            Layout::setContent($result->render());
            Response::setBody(Layout::getInstance());
        } else {
            Response::setBody($result);
        }
    }