title: modal window is causing the parent page body to scroll to the top
body: <p>i bought a theme and i am using the modal window feature. there is a button and when it is clicked the modal window opens. the coding is:-</p>
  
  <pre><code>&lt;button class="btn btn-modern btn-primary" data-toggle="modal" data-target="#largeModal"&gt;
  Launch Large Modal
  &lt;/button&gt;
  &lt;div class="modal fade" id="largeModal" tabindex="-1" role="dialog" aria-labelledby="largeModalLabel" aria-hidden="true"&gt;
     &lt;div class="modal-dialog modal-lg"&gt;
        &lt;div class="modal-content"&gt;
           &lt;div class="modal-header"&gt;
              &lt;h4 class="modal-title" id="largeModalLabel"&gt;Large Modal Title&lt;/h4&gt;
              &lt;button type="button" class="close" data-dismiss="modal" aria-hidden="true"&gt;&amp;times;&lt;/button&gt;
           &lt;/div&gt;
           &lt;div class="modal-body"&gt;
              &lt;p&gt;Lorem ipsum dolor sit amet, consectetur adipiscing elit. Curabitur pellentesque neque eget diam posuere porta. Quisque ut nulla at nunc &lt;a href="#"&gt;vehicula&lt;/a&gt; lacinia. Proin adipiscing porta tellus, ut feugiat nibh adipiscing sit amet. In eu justo a felis faucibus ornare vel id metus. Vestibulum ante ipsum primis in faucibus.&lt;/p&gt;
              &lt;p&gt;Lorem ipsum dolor sit amet, consectetur adipiscing elit. Curabitur pellentesque neque eget diam posuere porta. Quisque ut nulla at nunc &lt;a href="#"&gt;vehicula&lt;/a&gt; lacinia. Proin adipiscing porta tellus, ut feugiat nibh adipiscing sit amet. In eu justo a felis faucibus ornare vel id metus. Vestibulum ante ipsum primis in faucibus.&lt;/p&gt;
           &lt;/div&gt;
           &lt;div class="modal-footer"&gt;
              &lt;button type="button" class="btn btn-light" data-dismiss="modal"&gt;Close&lt;/button&gt;
           &lt;/div&gt;
        &lt;/div&gt;
     &lt;/div&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>you can test the theme preview here:-
  <a href="https://preview.oklerthemes.com/porto/7.2.0/elements-modals.html" rel="nofollow noreferrer">https://preview.oklerthemes.com/porto/7.2.0/elements-modals.html</a></p>
  
  <p>scroll down in the page and then click on "Launch Large Modal". you will see that the parent page body stays where it is when the modal window is opened and closed</p>
  
  <p>i used the exact same code in my website which is:-
  <a href="http://mdscomputers.ae/new/solutions.php" rel="nofollow noreferrer">http://mdscomputers.ae/new/solutions.php</a></p>
  
  <p>please scroll down and you will see test1, test2 and test3</p>
  
  <p>for test1 you have to click on the word test1 to open the modal window. when the modal window opens the page body scrolls to the top. when you click on close then the parent page body stays at the top</p>
  
  <p>for test2 you have to click anywhere in the box to open the modal window. the same issue as test1 happens</p>
  
  <p>for test3 you have to click on the Launch Large Modal button. the parent page body will scroll to the top but when i close the modal window then the parent page body will scroll back down to the box</p>
  
  <p>this is driving me crazy :( why is the parent page body scrolling to the top for me and why is it only scrolling down in test3 and not in test1 and test2?</p>
  
  <p>i need to disable the parent page body from scrolling to the top when the modal window is opened</p>