Sorting a SELECT with JQuery
Just a simple function to sort an already populated list. Obviously it would be easier to sort before populating, but there are the odd occasion where this is more complicated than you thought. Requirements : JQuery var selectOptions = $(“#selectId option”); Then, we just run the sort command on the options array – and this [...]
TabIndex in HTML
TabIndex is an attribute to HTML elements that tells the browser which control takes focus next when TAB is pressed. <input id=”one” tabindex=”3″ /> <input id=”two” tabindex=”1″ /> <input id=”three” tabindex=”2″ /> <input id=”four” tabindex=”4″ /> Here, once the page is loaded, the first TAB press will set focus to input two, and then subsequent [...]