Jester's cap states:

,{Tap},Sacrifice ~this~: Search target player's library for three cards and remove them from the game. Then that player shuffles his or her library.
Anything before the double dot sign ( : ) is a cost involved in activating the ability. So when you activate the cap, you need to be able to pay two mana, tap it and sacrifice it. Once the ability is on the stack, the cap is already in the graveyard. Stifle will only counter the activated ability, it will not bring back the cap.
Remember this is very different from nevenyrrals disk. The cost for activating the disk is paying one mana and tapping it. When the activation resolves, the disk is destroyed as well (unless it is indestructible of course), but stifling the disks ability will enable the opponent to trigger the disk when it untaps again.
Edit: I should really take less time to answer these questions thouroughly, so I would actually be first when I post my actual answer...