What’s the tabindex=”-1″ in bootstrap for

The tabindex attribute explicitly defines the navigation order for focusable elements (typically links and form controls) within a page. It can also be used to define whether elements should be focusable or not. [Both] tabindex=”0″ and tabindex=”-1″ have special meaning and provide distinct functionality in HTML. A value of 0 indicates that the element should … Read more

Bootstrap 3.0 – Fluid Grid that includes Fixed Column Sizes

edit: As lots of people seem to want to do this, I have written up a short guide with a more general use case here https://www.atlascode.com/bootstrap-fixed-width-sidebars/. Hope it helps. The bootstrap3 grid system supports row nesting which allows you to adjust the root row to allow fixed width side menus. You need to put in … Read more

Using bootstrap with bower

I finally ended using the following : bower install –save http://twitter.github.com/bootstrap/assets/bootstrap.zip Seems cleaner to me since it doesn’t clone the whole repo, it only unzip the required assests. The downside of that is that it breaks the bower philosophy since a bower update will not update bootstrap. But I think it’s still cleaner than using … Read more

Why does Bootstrap set the line-height property to 1.428571429?

The line-height is determined by dividing the targeted line-height size by the font-size. In this example, Bootstrap is baselining their line-height off of a 14px font-size. The target line-height is 20px: 20px รท 14px = 1.428571429 When determining your line-height, you want to make sure you have ample white space between your rows. This allows … Read more

Bootstrap combining rows (rowspan)

Divs stack vertically by default, so there is no need for special handling of “rows” within a column. div { height:50px; } .short-div { height:25px; } <link href=”https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css” rel=”stylesheet” /> <div class=”container”> <h1>Responsive Bootstrap</h1> <div class=”row”> <div class=”col-lg-5 col-md-5 col-sm-5 col-xs-5″ style=”background-color:red;”>Span 5</div> <div class=”col-lg-3 col-md-3 col-sm-3 col-xs-3″ style=”background-color:blue”>Span 3</div> <div class=”col-lg-2 col-md-2 col-sm-3 col-xs-2″ … Read more

Bootstrap col align right

Bootstrap 5 (update 2021) To right align elements in Bootstrap 5… float-right is now float-end text-right is now text-end ml-auto is now ms-auto Bootstrap 4 (original answer) Use float-right for block elements, or text-right for inline elements: <div class=”row”> <div class=”col”>left</div> <div class=”col text-right”>inline content needs to be right aligned</div> </div> <div class=”row”> <div class=”col”>left</div> … Read more

How do you enable the escape key close functionality in a Twitter Bootstrap modal?

It looks like this is an issue with how the keyup event is being bound. You can add the tabindex attribute to you modal to get around this issue: tabindex=”-1″ So your full code should look like this: <a href=”#my-modal” data-keyboard=”true” data-toggle=”modal”>Open Modal</a> <div class=”modal fade hide” id=’my-modal’ tabindex=’-1′> <div class=”modal-body”> <div>Test</div> </div> </div> For … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)