I want to select all content for a div when it gets selected (ie contenteditable div is switched to via "tab" on the keyboard). It might look something like:
document.getElementById("abc").addEventListener("select",function(){
document.execCommand('selectAll',false,null);
});
Why does this not work and how should I go about doing it? Any help is greatly appreciated!