0

I want to first include latest posts in my blog home page and then I want to create a row containing posts of a certain label. I want to display different rows of different labels.

That's how I want to design my blog. But I don't know how to code blogger so that posts of certain labels are shown in that row.

How do I call them or display them in that row?

Shayki Abramczyk
  • 36,824
  • 16
  • 89
  • 114
Maisha Maliha
  • 69
  • 1
  • 1
  • 8

1 Answers1

0

I think It's possible! Just need little bit hard work.

First add CSS.

Then search for

<b:include data='post' name='post' />

Now replace this code with this one -

<b:if cond='data:blog.url == data:blog.homepageUrl'> <b:loop values='data:post.labels' var='label'><b:if cond='data:label.isLast == &quot;true&quot;'>
 <b:if cond='data:label.name != &quot;Your First Label Name&quot;'><div class='row'><b:include data='post' name='post' /></div></b:if>
 <b:if cond='data:label.name != &quot;Your Second Label Name&quot;'><div class='row'><b:include data='post' name='post' /></div></b:if>
 <b:if cond='data:label.name != &quot;Your Third Label Name&quot;'><div class='row'> <b:include data='post' name='post' /></div></b:if>
  </b:if></b:loop><b:else/><b:include data='post' name='post' /></b:if>

Note: you should remember that every post should have one label. And don't forget to add class='column' in article.

I don't try it. Check it by yourself and give me feedback.