title: anchor link jump to carousel slide
body: <p>I have different anchor links in my navigation. Currently if you click the submenu i.e. "Beglaubigungen" your jumping to an normal anchor, which is the bootstrap slider. 
  But I want it additionally to slide within the slider to the relating slide. How can I do this?</p>
  
  <p><a href="https://i.stack.imgur.com/akRqS.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/akRqS.png" alt="enter image description here"></a></p>
  
  <p>The slider HTML:</p>
  
  <pre><code>&lt;ul class="list-inline"&gt;
      &lt;li&gt; &lt;a id="carousel-selector-0" class="selected"&gt; Example 1 &lt;/a&gt;&lt;/li&gt;
      &lt;li&gt; &lt;a id="carousel-selector-1" &gt; Example 2 &lt;/a&gt;&lt;/li&gt;
      &lt;li&gt; &lt;a id="carousel-selector-2" &gt; Example 3 &lt;/a&gt;&lt;/li&gt;              
  &lt;/ul&gt;
  
  &lt;div id="myCarousel" class="carousel slide"&gt;
     &lt;!-- main slider carousel items --&gt;
     &lt;div class="carousel-inner"&gt;
         &lt;div class="active item" data-slide-number="0"&gt; abcdefghi&lt;/div&gt;
         &lt;div class="item" data-slide-number="1"&gt; abcdefghi&lt;/div&gt;
         &lt;div class="item" data-slide-number="2"&gt; abcdefghi&lt;/div&gt;
     &lt;/div&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>My navbar:
  <a href="https://i.stack.imgur.com/BoH4C.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/BoH4C.png" alt="enter image description here"></a></p>
  
  <p><strong>WHAT I HAVE TRIED</strong></p>
  
  <p>I guess the anchor link must look sth like this for the navigation: </p>
  
  <pre><code>https://mydomain.de/#anchor?slide=2
  </code></pre>
  
  <p>I tried this, but its not working:</p>
  
  <pre><code>$(document).ready(function(){
  
  $('#myCarousel').carousel(window.location.hash.substring(1));
  
  });
  </code></pre>