- var_dump: documentation ( source)
- array_combine: documentation ( source)
- preg_match_all: documentation ( source)
<?php
$str = "abc(xxx@email.com);cde(ggg@gmail.com)";
Preg_match_all('/(\w+)\((.*?)\)/', $str, $match);
$emails = array_combine($match[2], $match[1]);
Var_dump($emails);