Sting from variable in If statement - help

I have string i put together from an array that created the if statement but it does not work,

here is the process to make the parameters for the if and they are finally put into $statement

$exclude = array(1=>'preg_match("/^mailto:/", $href)',
2=>'preg_match("/javascript:/", $href)',
'(preg_match("/^http:\/\/|https:\/\//", $href) && !preg_match("/".$domain."/", $href))',
'preg_match("/(\/{2,})$/", $href)',
'preg_match("/\?/", $href)',
'preg_match("/\#/", $href)',
'preg_match("/^https:\/\//", $href)');

//print_r($exclude);
foreach($exclude as $key =>$value){
if($key == count($exclude)){
$statement .= $value;
} else{
$statement .= $value.' || ';
}
}

echo $statement;

when i do this:

if($statement){

it won't work

here is the output i see from statement

preg_match("/^mailto:/", $href) || preg_match("/javascript:/", $href) || (preg_match("/^http:\/\/|https:\/\//", $href) && !preg_match("/".$domain."/", $href)) || preg_match("/(\/{2,})$/", $href) || preg_match("/\?/", $href) || preg_match("/\#/", $href) || preg_match("/^https:\/\//", $href)

Why can't this work or can it and i am missing something??
[1382 byte] By [vincenzobar] at [2007-11-19 22:42:27]
# 1 Re: Sting from variable in If statement - help
The simplest if statement executes command(s) if a condition evaluates as true. This does not apply with $statement's case because it's of type string...

Try using strlen():if(strlen($statement) > 0) {
Regards. :)
cherish at 2007-11-10 3:57:27 >