title: How to filter posts by category in Camaleon CMS?
body: <p>I am trying to filter posts by category in my Rails project, I am using Camaleon CMS. My basic requirement is to display only specific posts.</p>
  
  <p>For example, only those posts to be shown who belong to the category "Fruits"?</p>
  
  <p>Here is the code I have used:</p>
  
  <pre><code>  &lt;% current_site.the_posts(current_theme.get_field("recent_post_type")).latest.limit(current_theme.get_field("home_qty")).decorate.each do |post| %&gt;
        &lt;!-- PORTFOLIO ITEM --&gt;
        &lt;div class="col-lg-3 col-md-3 col-sm-6 col-xs-6 text-center discussion-bot-box"&gt;
          &lt;h4&gt;&lt;%= post.the_title %&gt; &lt;span&gt;(299)&lt;/span&gt;&lt;/h4&gt;
          &lt;p&gt;&lt;%= post.the_content.html_safe %&gt;&lt;/p&gt;
        &lt;/div&gt; &lt;!-- /col --&gt;
    &lt;% end %&gt;
  </code></pre>