Roundcube Community Forum

 

tinymce javascript error including fix

Started by soledk, September 14, 2007, 06:54:55 PM

Previous topic - Next topic

soledk

sending an email with subject but no body, results in javascript error, tinyMCE on line 1684

// check for empty body
  if ((input_message.value=='')&&(tinyMCE.getContent()==''))
   {
   if (!confirm(this.get_label('nobodywarning')))
    {
    input_message.focus();
    return false;
    }
   }

  return true;
  };


changeing it to the following removes the bug.


// check for empty body
  if (input_message.value=='')
   {
   if (!confirm(this.get_label('nobodywarning')))
    {
    input_message.focus();
    return false;
    }
   }

  return true;
  };

ravendawson

A javascript error ay also occur when a broken image is sent via e-mail. Also, there are two types of javascript errors you need to watch out for: syntax error and runtime error. Syntax error occurs when you make a mistake with your code; usually, when there is a missing character or typographical error. Runtime error, on the other hand, occurs when your script is not able to complete the instructions or if a specific object cannot be found.