If i select a text from a text area i need to know which text is selected, for example "hello world" if i select hello i would like to see hello is selected how can i do this in jquery. and i want to make it bold.
<textarea id="editor" cols="80" rows="20">
Hello world, This is Me!
</textarea>
<button onclick="SelectText()">
Bold
</button>