title: onClick table row with onClick Button and Bootstrap Modal inside
body: <p>I want to open a generated link, if the user click on the table row. In this row i have a delete button. If the delete button clicked i want to open the modal. </p>
  
  <p>Every time i clicked on the delete button, the table row will be clicked too.</p>
  
  <p>I found <a href="https://stackoverflow.com/questions/2385113/howto-div-with-onclick-inside-another-div-with-onclick-javascript">this</a> but then the modal doesnt work. 
  And i found <a href="https://stackoverflow.com/questions/2015041/two-differents-onclick-on-two-divs-one-over-the-other/2015219#2015219">this</a> but there is my target everytime Null.</p>
  
  <p>Why it doesn't work? And how i can solve this problem?</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-js lang-js prettyprint-override"><code>function show_clothing(t_row) {
  
    var link = $(t_row).attr('data-href');
    console.log("Redirect to : " + link);
  
  }
  
  function delete_clothing(btn) {
  
    var clothing_id = $(btn).attr('data-clothing_id');
    console.log("Delete : " + clothing_id);
  }</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.3/umd/popper.min.js"&gt;&lt;/script&gt;
  &lt;script src="https://code.jquery.com/jquery-3.3.1.slim.min.js"&gt;&lt;/script&gt;
  &lt;link href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.1/css/bootstrap.min.css" rel="stylesheet" /&gt;
  &lt;script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"&gt;
  &lt;/script&gt;
  &lt;table class="table table-light"&gt;
    &lt;thead&gt;
      &lt;tr&gt;
        &lt;th scope="col"&gt;ID&lt;/th&gt;
        &lt;th scope="col"&gt;Button&lt;/th&gt;
      &lt;/tr&gt;
    &lt;/thead&gt;
    &lt;tbody&gt;
      &lt;tr onclick="show_clothing(this)" data-href="a_link"&gt;
        &lt;td&gt;#34&lt;/td&gt;
        &lt;td&gt;
          &lt;button data-toggle="modal" data-target="#deleteModalCenter" class="btn btn-danger btn-sm" data-clothing_id="34" onclick="delete_clothing(this)"&gt;Delete&lt;/button&gt;
        &lt;/td&gt;
      &lt;/tr&gt;
    &lt;/tbody&gt;
  &lt;/table&gt;
  
  
  
  
  &lt;div class="modal fade" id="deleteModalCenter" tabindex="-1" role="dialog" aria-labelledby="deleteModalCenterTitel" aria-hidden="true"&gt;
    &lt;div class="modal-dialog modal-dialog-centered" role="document"&gt;
      &lt;div class="modal-content"&gt;
        &lt;div class="modal-header"&gt;
          &lt;h5 class="modal-title" id="exampleModalLongTitle"&gt;Delete clothing&lt;/h5&gt;
          &lt;button type="button" class="close" data-dismiss="modal" aria-label="Close"&gt;
            &lt;span aria-hidden="true"&gt;&amp;times;&lt;/span&gt;
          &lt;/button&gt;
        &lt;/div&gt;
        &lt;div class="modal-body"&gt;
            &lt;p id="modal_text"&gt;Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam &lt;/p&gt;
            &lt;p id="modal_text_small"&gt;Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam &lt;/p&gt;
        &lt;/div&gt;
        &lt;div class="modal-footer"&gt;
           &lt;a&gt;&lt;button type="button" class="btn btn-secondary" data-dismiss="modal"&gt;chancel&lt;/button&gt;&lt;/a&gt;
          &lt;a id="delete_btn" href="/delete_person/"&gt;&lt;button type="button" class="btn btn-danger"&gt;delete&lt;/button&gt;&lt;/a&gt;
        &lt;/div&gt;
      &lt;/div&gt;
    &lt;/div&gt;
  &lt;/div&gt;</code></pre>
  </div>
  </div>
  </p>