I want to show the dropdown box programatically using Twitter boostrap 3.
Following is the piece of code
<div class="link-propery">
<div class="dropdown">
<a href="#" data-toggle="dropdown" class="dropdown-toggle">
<!--
I don't want to use this for clicking and then showing Dropdown
<b class="caret"></b>
-->
</a>
<ul class="dropdown-menu">
<li><a href="#">Action</a></li>
<li><a href="#">Another action</a></li>
<li class="divider"></li>
<li><a href="#">Separated link</a></li>
</ul>
</div>
</div>
And when I type this in the console, the dropbox isn't visible:
$(".dropdown-toggle").dropdown();
I want to show the dropdown using programatically and not by clicking some button or link. Is there a way to do this ? Also, I have demoed the same problem using jsbin.
This makes the dropdown show programtically:
$(".dropdown-toggle").trigger("click");