title: How to open a second bootstrap3 modal window only after passing validation?
body: <p>I have two modal windows, the first window has the form with validator (<a href="http://1000hz.github.io/bootstrap-validator" rel="nofollow">http://1000hz.github.io/bootstrap-validator</a>), and the second with the text like "Thanks for posting." I wrote this code for my input button: </p>
  
  <pre><code>&lt;input data-dismiss="modal" data-toggle="modal" data-target="#thanks" type="submit" value="Отправить" class="btn btn-primary btn-block btn-md button-space"&gt;
  </code></pre>
  
  <p>But when I click on this button the first window is closed without checking the validation. How can I fixed that?</p>