what are the + signs for?
to me it looks like your trying to concatenate the string, javascript style.
in php you use . to concatenate
<?php
$variable = "test";
if (preg_match("/" . $variable . "/", "testing")) {
echo "A match was found.";
} else {
echo "A match was not found.";
}
// or just
$variable = "test";
if (preg_match("/$variable/", "testing")) {
echo "A match was found.";
} else {
echo "A match was not found.";
}
?>