Token storage in DB means that length for some of these goes beyond the current 255 character limit on varchar.
Length is set in includes/webform.emails.inc
$form[$field . '_custom'] = array(
'#type' => 'textfield',
'#size' => 40,
'#default_value' => (!is_numeric($email[$field]) && $email[$field] != 'default') ? $email[$field] : NULL,
'#maxlength' => $field == 'email' ? 500 : 255,
);
($field would = 'subject' - in this case - the other 2 possibilities are from_name & from_address - I'm unsure as to whether they could wind up blowing out with tokens)
& in the schema / DB field itself.
Comments
Comment #1
torrance123 commentedI agree — it seems unnecessary to limit the subject line to 255 characters, especially if we're using verbose tokens.
Please see attached patch against the 7.x-4.x branch which changes the database columns to type 'TEXT' (thus matching the email field) and increases the #maxlength property to 500.
Comment #2
xurizaemon+1. NB the limit on emails doesn't relate to RFC, since we store multiple emails in the same field comma separated.
* #277581: Send emails with a custom/templated body (and subject, to addresses and from addresses) - 255 char limit on other fields
* #848386: Extend limit of 128 characters for "To:" addresses in custom email - 500 char limit on emails
Comment #3
torrance123 commentedSeems all good.
Comment #4
quicksketchThanks guys! Tested and works fine here too. Committed to 7.x-4.x branch as-is.
Comment #6
fenstratNeeds porting to 8.x-4.x.
Comment #7
fenstratCommitted and pushed 06b32c6 to 8.x-4.x.