title: Check if current date lies between start date and end date (Laravel 5.3)
body: <p>So, I have this view in my controller to show a button if the current date lies between the start date and the end date. Here is what I have done so far :</p>
  
  <pre><code>@if (Carbon\Carbon::now()-&gt;format('Y-m-d') &lt; Carbon\Carbon::parse($edition-&gt;start)-&gt;format('Y-m-d') &amp;&amp; Carbon\Carbon::now()-&gt;format('Y-m-d') &gt; Carbon\Carbon::parse($edition-&gt;end)-&gt;format('Y-m-d'))
       &lt;p&gt;&lt;/p&gt;
  @else
       &lt;div class="tombol-nav"&gt;
         &lt;a href="../journal/create?edition={{$edition-&gt;id}}" class="btn btn-primary"&gt;Upload Jurnal Anda Sekarang!&lt;/a&gt;&lt;br&gt;
         &lt;p style="color: red;"&gt;Penting! Batas waktu terakhir pengunggahan Jurnal pada Edisi ini : {{ Carbon\Carbon::parse($edition-&gt;limit)-&gt;format('j F, Y') }}&lt;/p&gt;
       &lt;/div&gt;
  @endif
  </code></pre>
  
  <p>I don't know what's wrong with it, the button will still appear even though the end date has passed. Thank you for your help.</p>