I was trying to create twitter bootstrap submenu in dropdown menu, but I've got a problem: I have dropdown menu in the top right corner of the page and that menu has one more submenu. However, when submenu opens - it does not fit in the window and goes too much to the right, so that user can see only first letters. How to make that submenu to open not to the right, but to the left?
Example Explained dropdown class indicates a dropdown menu. To open the dropdown menu, use a button or a link with a class of . dropdown-toggle and the data-toggle="dropdown" attribute. The .
If I've understood this right, bootstrap provides a CSS class for just this case. Add 'pull-right' to the menu 'ul':
<ul class="dropdown-menu pull-right">
..and the end result is that the menu options appear right-aligned, in line with the button they drop down from.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With