This question has been asked in a few different formats but I can\'t get any of the answers to work in my scenario.
I am using jQuery to implement command history wh
2 artlung's answer: It works with second line only in my code (IE7, IE8; Jquery v1.6):
var input = $('#some_elem'); input.focus().val(input.val());
Addition: if input element was added to DOM using JQuery, a focus is not set in IE. I used a little trick:
input.blur().focus().val(input.val());