title: Javascript onclick show/hide for multiple rows (Dynamic content)
body: <p>I'm having a list of users where the admin can approve/decline.For these two action i'm using show/hide oncllick the code works.But in multiple rows for any action button onclick it shows/hide the content.I want paticular row's  action button 'ld show/hide the content,on click of that button.How can I solve this?
   Here is My view code laravel blade,</p>
  
  <pre><code>&lt;script&gt;
      function showhide() {  
          var div = document.getElementById("collapse1");  
          if (div.style.display !== "none")   
              div.style.display = "none";  
          else  
              div.style.display = "block";  
      }  
      &lt;/script&gt;       
  </code></pre>
  
  <p><strong>Content:</strong></p>
  
  <pre><code>&lt;div&gt;
      &lt;button href="#collapse1" class="btn btn-success nav-toggle"  onclick="showhide()"&gt;Action&lt;/button&gt;
  &lt;/div&gt;
  @if($user-&gt;approved == 0)
  &lt;div id="collapse1" style="display:none"&gt;
      &lt;span&gt;
          &lt;a href="{!! route('approve', ['id' =&gt; $user-&gt;id]) !!}"&gt;&lt;img alt="" src="http://www.clker.com/cliparts/l/n/a/E/b/t/check-mark-button-hi.png" 
          style="height: 48px; width: 48px"  /&gt;&lt;/a&gt;
      &lt;/span&gt;&lt;br/&gt;
  @else
      &lt;span&gt;
          &lt;a href="{!! route('decline', ['id' =&gt; $user-&gt;id]) !!}"&gt;
              &lt;img alt="" src="https://images.onlinelabels.com/images/clip-art/TzeenieWheenie/TzeenieWheenie_red_green_OK_not_OK_Icons_1.png" 
      style="height: 48px; width: 48px"/&gt;
          &lt;/a&gt;
      &lt;/span&gt;
  &lt;/div&gt;
  @endif
  </code></pre>
  
  <p><strong>Script</strong></p>
  
  <pre><code>@pushonce('custom-scripts')
   &lt;script 
    src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"&gt;
    &lt;/script&gt;
   @endpushonce
  </code></pre>