@
RemRain 下面的正则能处理一些情况,但还不够
$_relation = array('A'=>'#1','B'=>'#2",'C'=>'#3','D'=>'#4');
$comment = preg_replace(
array(
'/([^A-Za-z0-9\“\”]+|^)\s*([a-eA-E\、\.\,\,\s]+)\s*([^A-Za-z0-9\“\”]+?|$)/iuesm',
),
array(
"'\$1'.(((strpos('$question', '\$2') === FALSE AND substr_count('$comment', '\$2') < 3) OR (strpos('$question', substr('\$1', -1).'\$2'.substr('\$3', 0, 1)) === FALSE AND preg_match('/(解析*|答案*|排*除|正确|对|错误*|选|项|是)/iues', '\$1\$2\$3'))) ? strtr(strtoupper('\$2'), $_relation) : '\$2').'\$3'",
),
$comment
);