function search_explode($r, $s) {
$ret = array();
$i = 0;
$j = 0;
for ($c = 0; $c < strlen($s); $c++) {
if ($s[$c] == '"' or $s[$c] == "'") {
if ($j == 0) {
$j = 1;
} else {
$j = 0;
}
}
if ($s[$c] != $r) {
$ret[$i] .= $s[$c];
} else {
if ($j) {
$ret[$i] .= $s[$c];
} else {
$i++;
}
}
}
return $ret;
}