mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-23 14:28:45 +01:00
encapsulate adaption of subject in function, and use it
This commit is contained in:
parent
d5d6f4daf9
commit
9d5eb54b47
@ -5227,6 +5227,19 @@ class felamimail_bo
|
||||
return $message;
|
||||
}
|
||||
|
||||
/**
|
||||
* adaptSubjectForImport - strips subject from unwanted Characters, and does some normalization
|
||||
* to meet expectations
|
||||
* @param string $subject string to process
|
||||
* @return string
|
||||
*/
|
||||
static function adaptSubjectForImport($subject)
|
||||
{
|
||||
$subject = str_replace('$$','__',($subject?$subject:lang('(no subject)')));
|
||||
$subject = str_ireplace(array('[FWD]','[',']','{','}','<','>'),array('Fwd:',' ',' ',' ',' ',' ',' '),trim($subject));
|
||||
return $subject;
|
||||
}
|
||||
|
||||
/**
|
||||
* processURL2InlineImages - parses a html text for images, and adds them as inline attachment
|
||||
* we do not use the functionality of the phpmailer here, as phpmailers functionality requires
|
||||
|
Loading…
Reference in New Issue
Block a user