cross-browser insert an html string at the cursor position, or over the selected text.