How to set cursor at the end in a textarea?
selectionStart is enough to set initial cursor point.
element.focus();
element.selectionStart = element.value.length;
There may be many ways, e.g.
element.focus();
element.setSelectionRange(element.value.length,element.value.length);
http://jsfiddle.net/doktormolle/GSwfW/