\Yii::$app->view->title = $jobItem['systitle'] . " - " . $jobItem['company']['systitle']; // JsonLD $slugger = new Slugify(); $doc = (object)[ '@context' => 'https://schema.org', '@type' => 'JobPosting', "title" => $jobItem['systitle'], 'description' => !empty($jobItem['description']) ? $jobItem['description'] : 'Eines von vielen interessanten Stellenangeboten auf forum-holzkarriere.com', "datePosted" => strftime('%Y-%m-%d', $jobItem['created']), "validThrough" => strftime('%Y-%m-%d', strtotime("+3 months", time())), "employmentType" => "Full-time", "hiringOrganization" => [ "@type" => "Organization", "name" => $jobItem['company']['systitle'], "sameAs" => $jobItem['company']['link'], "logo" => "https://www.forum-holzkarriere.com" . $jobItem['company']['logo']['src'], ], "jobLocation" => [
$slugger = new Slugify(); $doc = (object)[ '@context' => 'https://schema.org', '@type' => 'JobPosting', "title" => $jobItem['systitle'], 'description' => !empty($jobItem['description']) ? $jobItem['description'] : 'Eines von vielen interessanten Stellenangeboten auf forum-holzkarriere.com', "datePosted" => strftime('%Y-%m-%d', $jobItem['created']), "validThrough" => strftime('%Y-%m-%d', strtotime("+3 months", time())), "employmentType" => "Full-time", "hiringOrganization" => [ "@type" => "Organization", "name" => $jobItem['company']['systitle'], "sameAs" => $jobItem['company']['link'],
try { /* @var $widget Widget */ $config['class'] = get_called_class(); $widget = Yii::createObject($config); $out = ''; if ($widget->beforeRun()) { $result = $widget->run(); $out = $widget->afterRun($result); } } catch (\Exception $e) { // close the output buffer opened above if it has not been closed already if (ob_get_level() > 0) { ob_end_clean();
public function call($className, $method, $arguments = null) { $callable = [$className, $method]; if ($arguments === null) { return call_user_func($callable); } else { return call_user_func_array($callable, $arguments); } } /** * Resolves class name from widget and asset syntax *
* @param string $method method name * @param array $arguments * @return mixed */ public function resolveAndCall($className, $method, $arguments = null) { return $this->call($this->resolveClassName($className), $method, $arguments); } /** * Calls a method * * @param string $className class name
* @param array $config widget config * @return mixed */ public function widget($widget, $config = []) { return $this->resolveAndCall($widget, 'widget', [ $config, ]); } /** * Used for 'begin_page', 'end_page', 'begin_body', 'end_body', 'head' *
<div class=\"content-wrap\"> <div class=\"container clearfix\"> <div class=\"col_three_fourth\" style=\"margin: 0 auto; float: none;\"> "; // line 23 echo $this->extensions['yii\twig\Extension']->widget("job_display"); echo " </div> <div class=\"clear\"></div> </div>
return ob_get_clean(); } protected function displayWithErrorHandling(array $context, array $blocks = []) { try { $this->doDisplay($context, $blocks); } catch (Error $e) { if (!$e->getSourceContext()) { $e->setSourceContext($this->getSourceContext()); } // this is mostly useful for \Twig\Error\LoaderError exceptions
{ return $this->blocks; } public function display(array $context, array $blocks = []) { $this->displayWithErrorHandling($this->env->mergeGlobals($context), array_merge($this->blocks, $blocks)); } public function render(array $context) { $level = ob_get_level(); if ($this->env->isDebug()) {
if ($this->env->isDebug()) { ob_start(); } else { ob_start(function () { return ''; }); } try { $this->display($context); } catch (\Throwable $e) { while (ob_get_level() > $level) { ob_end_clean(); } throw $e;
* @param array $context An array of parameters to pass to the template */ public function render(array $context = []): string { // using func_get_args() allows to not expose the blocks argument // as it should only be used by internal code return $this->template->render($context, \func_get_args()[1] ?? []); } /** * Displays the template. * * @param array $context An array of parameters to pass to the template
* @throws LoaderError When the template cannot be found * @throws SyntaxError When an error occurred during compilation * @throws RuntimeError When an error occurred during rendering */ public function render($name, array $context = []) { return $this->load($name)->render($context); } /** * Displays a template. * * @param string|TemplateWrapper $name The template name
// Change lexer syntax (must be set after other settings) if (!empty($this->lexerOptions)) { $this->setLexerOptions($this->lexerOptions); } return $this->twig->render(pathinfo($file, PATHINFO_BASENAME), $params); } /** * Adds aliases * * @param \Twig_Loader_Filesystem $loader
if (isset($this->renderers[$ext])) { if (is_array($this->renderers[$ext]) || is_string($this->renderers[$ext])) { $this->renderers[$ext] = Yii::createObject($this->renderers[$ext]); } /* @var $renderer ViewRenderer */ $renderer = $this->renderers[$ext]; $output = $renderer->render($this, $viewFile, $params); } else { $output = $this->renderPhpFile($viewFile, $params); } $this->afterRender($viewFile, $params, $output); }
* @throws InvalidCallException if the view cannot be resolved. * @see renderFile() */ public function render($view, $params = [], $context = null) { $viewFile = $this->findViewFile($view, $context); return $this->renderFile($viewFile, $params, $context); } /** * Finds the view file based on the given view name. * @param string $view the view name or the [path alias](guide:concept-aliases) of the view file. Please refer to [[render()]] * on how to specify this parameter.
* These parameters will not be available in the layout. * @return string the rendering result. * @throws InvalidArgumentException if the view file or the layout file does not exist. */ public function render($view, $params = []) { $content = $this->getView()->render($view, $params, $this); return $this->renderContent($content); } /** * Renders a static string by applying a layout. * @param string $content the static string being rendered
\Yii::$app->view->registerMetaTag([ 'name' => 'description', 'content' => $data['metadescription'] ]); } return $this->render($this->viewTemplate, ['data' => $data]); } /** * [resolvePathRequested description] * @return [type] [description] */
$args = $this->controller->bindActionParams($this, $params); Yii::debug('Running action: ' . get_class($this->controller) . '::' . $this->actionMethod . '()', __METHOD__); if (Yii::$app->requestedParams === null) { Yii::$app->requestedParams = $args; } return call_user_func_array([$this->controller, $this->actionMethod], $args); } }
} $result = null; if ($runAction && $this->beforeAction($action)) { // run the action $result = $action->runWithParams($params); $result = $this->afterAction($action, $result); // call afterAction on modules foreach ($modules as $module) { /* @var $module Module */
$parts = $this->createController($route); if (is_array($parts)) { /* @var $controller Controller */ list($controller, $actionID) = $parts; $oldController = Yii::$app->controller; Yii::$app->controller = $controller; $result = $controller->runAction($actionID, $params); if ($oldController !== null) { Yii::$app->controller = $oldController; } return $result; }
$params = $this->catchAll; unset($params[0]); } try { Yii::debug("Route requested: '$route'", __METHOD__); $this->requestedRoute = $route; $result = $this->runAction($route, $params); if ($result instanceof Response) { return $result; } $response = $this->getResponse(); if ($result !== null) {
{ try { $this->state = self::STATE_BEFORE_REQUEST; $this->trigger(self::EVENT_BEFORE_REQUEST); $this->state = self::STATE_HANDLING_REQUEST; $response = $this->handleRequest($this->getRequest()); $this->state = self::STATE_AFTER_REQUEST; $this->trigger(self::EVENT_AFTER_REQUEST); $this->state = self::STATE_SENDING_RESPONSE; $response->send();
require(__DIR__ . '/../vendor/autoload.php'); require(__DIR__ . '/../vendor/yiisoft/yii2/Yii.php'); $config = require(__DIR__ . '/../config/web.php'); (new yii\web\Application($config))->run();
$_GET = [ 'category' => 'Praktikum / Arbeiten', 'pathRequested' => 'stellendetail', 'language' => '', 0 => [ 'f280e46c-ba3e-410c-ab49-aab0acf7f403', 'stellen.html', ], ];