title: How can I use join and where together - Laravel?
body: <p>I want to establish a relationship between two tables. So I want to bring blogs with status = 1. How can I do that.
  My categories table looks like</p>
  
  <pre><code>id|category_name|status|
  1 |Animals      |   0     
  2 |Education    |   1     
  3 |Water        |   0    
  </code></pre>
  
  <p>My blogs table looks like</p>
  
  <pre><code>id|category_id|title      | description         |
  1 |   1       |New Post 1 | Post description 1  |
  2 |   2       |New Post 2 | Post description 1  |
  3 |   3       |New Post 3 | Post description 1  |
  4 |   2       |New Post 4 | Post description 1  |
  </code></pre>
  
  <p>How do I list blogs provided that where('status', 1) from categories table?
  Please help me. thanks for your help.</p>