How to display the content of a blog post

Kayla Johnson asked on August 14, 2014 19:38

I've created a blog on the site and on the home page, have a web part zone for recent posts. http://grab.by/ztvu And I can click into the different blog posts. But once I'm on each individual blog post page it still shows the same content, like it's inheriting it from some parent template page. I don't really understand it. Blog posts are set to inherit from the Blog Post Template I created. But it's getting content from the Home Page Template as well as the Comments Web Part that I put on the Blog Post Template. I just want to get the title and content of the blog post on the blog post page. It's not intuitive in the slightest.

Recent Answers


Joshua Adams answered on August 14, 2014 19:59

There should be two different transformations...the first one will be the main view, so this would be a preview of the post, aka your title and a small snippet or something. Then you would have your selected item transformation to be when you click on the post. This is where you would show all of the content of the blog and allow the reader to read the whole thing or leave comments, etc. Does that make sense? Try looking at the transformations and select the blog post preview transformation for the first one and then for the selected item transformation select the blog post default transformation.

0 votesVote for this answer Mark as a Correct answer

Kayla Johnson answered on August 14, 2014 22:42

Josh,

Are you saying I should create some transformations? The only blog post transformations I have are for archive, atomitem, default, recentposts and rssitem. Default seems like it should work. But I don't know how to insert a transformation into a templte.

0 votesVote for this answer Mark as a Correct answer

Joshua Adams answered on August 14, 2014 22:57

There should be an option to create a new one...do that for the main one, and then use the default for the selected. The only you create, try to generate a default one and then take out everything besides the blogpost title or whatever you want to show up.

0 votesVote for this answer Mark as a Correct answer

Kayla Johnson answered on August 15, 2014 00:48

I'm running in circles here. I have a home page that has a web part that has a Recent Post web part. And it shows recent blog posts of the blog that's a "subpage" of that page. Then the calendar archive view of the posts and the posts themselves also are using that template because they are a child of the home page.. And as soon as I go into the blog itself or the blog posts, there's two green sections. I think those are for templates. http://grab.by/zu9g why?

Now if I go into document types and select Blog post and look at its transformations. There's a default one that displays what I want for now. But how do I hook up this transformation to each blog post? I want, when I view a single blog post, it shows this stuff. http://grab.by/zu9k I shouldn't have to do anything. This is the default display for blog posts right?

The only video tutorials I can find are on using the wysiwyg editor or don't even load. http://www.kentico.com/Product/All-Features/Social-Networking/Blogs

0 votesVote for this answer Mark as a Correct answer

Juraj Ondrus answered on August 15, 2014 01:03

Hi,

I would recommend using the corporate sample site for inspiration. In general, you should have two different page templates - one used to list the blogs and one for the actual blog posts. You can have one template as well but then you need to set which web parts are displayed for which document type or level (using show for document types or hide on subpages properties). The idea is similar to a news listing.

FYI: https://docs.kentico.com/display/K8/Creating+blog+posts

1 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.