Is there any way to have a condition for an if statement be evaluated according to its contents and not whether the variable is defined or not? In other words: $a = 'no';
$the_condition = '$a == "yes"';
if($the_condition)
{
echo "$a is equal to yes";
}
else
{
echo "$a is not equal to yes";
}
This will always evaluate as true and print yes because $the_condition variable is defined.
Is there any syntax so that I can have it actually evaluate the condition within the variable and whether that is true or not?