title = "newPost" url = "/new/post/:id/:slug" layout = "new/master-inside" is_hidden = 0 robot_index = "index" robot_follow = "follow" [views] slug = "{{ :slug }}" [blogPost] slug = "{{ :slug }}" id = "{{ :id }}" categoryPage = 404 == page->blogPost); $postId = $this->param('id'); $currentPost = RainLab\Blog\Models\Post::where('id', $postId)->with(['category_groups'])->first(); if($this->menuItems && $postId && $currentPost && $currentPost->category_groups){ $currentGroup = $currentPost->category_groups[0]->name; foreach ($this->menuItems as $menu){ //dump($menu->title); if($menu->title === $currentGroup){ $menu->isActive = true; break; } } } } ?> == {% put styles %} {% endput %} {% set post = blogPost.post %}

{{post.title}}

{{post.published_at|date('d.m.Y')}} | {{post.published_at|date('H:i')}}
 {{post.title}}
{{post.content|md}}
{% partial 'new/social' %}
{% partial 'new/post-featured' %}
{% partial 'newHome/right-sidebar.htm' class="article-aside" %}
{% put scripts %} {% endput %}