XSLT: Checking for the absence of an element

I’ve seen how to check for the presence of an element but what I want to do is the opposite. Is there any way to negate the xsl:if? Or is this another easy way?

Yeah that’s what I went with. I also found that you can create a nodeset and compare it to the false() method and that will work, too.

Something like this I believe:

     <xsl:when test="/bar/foo">
          <p>not present</p>