Trigger Twitter Bootstrap tooltip on a form input

Trigger Twitter Bootstrap tooltip on a form input

Last updated:

Create the <input> with the required rel and title attributes:

<input type="text" rel="tooltip" title="Search All Items">

Trigger tooltip:

$(document).ready(function(){
    $('input[title]').tooltip({placement:'bottom'});
})

using another selector:

$(document).ready(function(){
    $('input[rel="tooltip"]').tooltip();
});