Hey boss, I'm going to write this wordpress plugin as a side project. I'll be doing on my own time and with my own equipment. I'd like the company to disclaim any right to the code.
9 times out of 10 they will do so. If they don't then you know it's time to polish the resume. As tptacek says elsewhere here. It's too good a job market to risk the legal hassle of working someplace like that.
And, people hear what they want to hear. The employee hears, "good luck with that project, great idea!" and thinks that means the employer doesn't want a stake in it. The employer might simply be intending to encourage the employee, thinking the project is obviously company owned.
"Having the conversation" only muddies the waters.
However, in that case, a legal fight may be somewhat tenable (though it always sucks for everyone (except lawyers)). If you got them to sign a document releasing the project, you'll be able to win that much more easily.
If you can get the signature without too much hassle, it's worth it. If you can't, it's not worth ever mentioning it, IMO.
This. I know Amazon is good at this.
If you, the employee, are working for an employer you respect, and vice versa, YOU CAN HAVE A CONVERSATION!
If your day job is, say, maintaining high-capacity forum software in dotnet, and you have this hankering to develop, say, a WordPress plugin to show the time of sunrise, you can talk about it.
If you respect your boss and she respects you, the conversation will be fruitful. She may say, "please don't do that," and you'll understand why not. She may say "go ahead."
If you DON'T respect your boss, there's lots of advice here about how to proceed. But why not start out assuming mutual respect?