function insert_smiley(what)
 {
  if (document.forms['comment-public'].elements['comment_content'].createTextRange)
   {
    document.forms['comment-public'].elements['comment_content'].focus();
    document.selection.createRange().duplicate().text = what;
   }
  else if ((typeof document.forms['comment-public'].elements['comment_content'].selectionStart) != 'undefined') // für Mozilla
   {
    var tarea = document.forms['comment-public'].elements['comment_content'];
    var selEnd = tarea.selectionEnd;
    var txtLen = tarea.value.length;
    var txtbefore = tarea.value.substring(0,selEnd);
    var txtafter =  tarea.value.substring(selEnd, txtLen);
    var oldScrollTop = tarea.scrollTop;
    tarea.value = txtbefore + what + txtafter;
    tarea.selectionStart = txtbefore.length + what.length;
    tarea.selectionEnd = txtbefore.length + what.length;
    tarea.scrollTop = oldScrollTop;
   }
  else
   {
    document.forms['comment-public'].elements['comment_content'].value += what;
   }
 }

