How do I make my phone play a ringtone over my headphones despite being on "silent"? I'm running Cyanogenmod 7.1RC1 on my Desire.

When my phone is not on silent, I can hear the ringtone on my headphones when someone calls me, which is great. However, when my phone is on silent and my headphones are plugged in, an incoming call will not produce a ringtone over the headphones. I would prefer it if my phone, despite being on silent, would play a ringtone over my headphones if they are plugged in. Is there any way to make this happen?
You could create a tasker profile that sets the ringer volume when a Bluetooth headset is connected.

I'm not sure how to handle the case when you disconnect the headset,  though.  You would only want to set the volume back to zero if it was zero when it was connected.

Edit: tasker gives access to current ringer volume via variable %volr

In a profile with condition Bluetooth connected:

Set a variable %savevol to %volr

Set ringer volume to desired level, if %volr = 0

Exit task: set ringer volume to 0, if % savevol = 0