Create an anchor element and click and go to it
<p>I am trying to go to a specific link with jquery but my code does not do it</p>

<p>None of this works</p>

<pre><code>$("&lt;a class='tab-link' href='cnn.com'&gt;cnn&lt;/a&gt;").trigger('click');
$("&lt;a class='tab-link' href='cnn.com'&gt;cnn&lt;/a&gt;").click();
</code></pre>

<p>This is the fiddle <a href="https://jsfiddle.net/hmkLwme9/7/" rel="nofollow">https://jsfiddle.net/hmkLwme9/7/</a></p>

<p>The link i want to visit must have the class <code>tab-link</code></p>

<p>How can i do this in jquery?</p>