Hi, I'm having troubles figuring the regex pattern out for this here: cc “[email protected]” The email is changing the cc “{email}” stays always the same. So what would it be so I can extract the email out of this string. PS: This is just an extract from the custom_mailfilter, so there is more text around it.
maybe this gives you a hint: PHP: <?php$str = "asdasasasd cc \"[email protected]\" asdasdasdsad";if( preg_match("/cc \"(.*)\"/", $str, $matches) ) { var_dump($matches);}else { //String was not found}?> where $matches[1] would be the string within "". You might also think of using another regex to match a more or less real syntax for emailadresses instead of matching any string between "" ( -> (.*) ).