I've tried a bunch of different things, Google, etc with no luck.

I've got a php variable. I want to say that if the variable equals the entry category, then print some text.

Here's what isn't working (it's inside of an entry loop, of course):

CODE
<mt:If tag="EntryCategory" eq="<?php echo $urlState; ?>">


<?php echo "Yes, DC!"; ?>

<mt:else>
<?php echo "Sorry, not dc."; ?>
</mt:if>


It always prints the "sorry not dc." How do I get this going?

update. fixed it. did it all in the php part:

CODE
$category = "<$MTCategoryLabel$>";
if ($category == $urlState)
echo "success!";